VippsStatus.fromJson constructor
Implementation
factory VippsStatus.fromJson(Map<String, dynamic> json) =>
switch (json['status']) {
'PENDING' => VippsPending.fromJson(json),
'COMPLETED' => VippsCompleted.fromJson(json),
'FAILED' => VippsFailed.fromJson(json),
final String status => VippsUnknown(status: status),
_ => throw IdentisureException(
0, 'Invalid vipps status: ${json['status']}'),
};