PaymentMethodOptionsPix.fromJson constructor

PaymentMethodOptionsPix.fromJson(
  1. Object? json
)

Implementation

factory PaymentMethodOptionsPix.fromJson(Object? json) {
  final map = (json as Map).cast<String, Object?>();
  return PaymentMethodOptionsPix(
    expiresAfterSeconds: map['expires_after_seconds'] == null
        ? null
        : (map['expires_after_seconds'] as num).toInt(),
    expiresAt:
        map['expires_at'] == null ? null : (map['expires_at'] as num).toInt(),
  );
}