PaymentMethodDetailsCardWalletVisaCheckout.fromJson constructor

PaymentMethodDetailsCardWalletVisaCheckout.fromJson(
  1. Object? json
)

Implementation

factory PaymentMethodDetailsCardWalletVisaCheckout.fromJson(Object? json) {
  final map = (json as Map).cast<String, Object?>();
  return PaymentMethodDetailsCardWalletVisaCheckout(
    billingAddress: map['billing_address'] == null
        ? null
        : Address.fromJson(map['billing_address']),
    email: map['email'] == null ? null : (map['email'] as String),
    name: map['name'] == null ? null : (map['name'] as String),
    shippingAddress: map['shipping_address'] == null
        ? null
        : Address.fromJson(map['shipping_address']),
  );
}