CheckoutSessionAfterExpirationRecovery.fromJson constructor
CheckoutSessionAfterExpirationRecovery.fromJson(
- Object? json
Implementation
factory CheckoutSessionAfterExpirationRecovery.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return CheckoutSessionAfterExpirationRecovery(
allowPromotionCodes: (map['allow_promotion_codes'] as bool),
enabled: (map['enabled'] as bool),
expiresAt: map['expires_at'] == null
? null
: DateTime.fromMillisecondsSinceEpoch(
(map['expires_at'] as int).toInt()),
url: map['url'] == null ? null : (map['url'] as String),
);
}