copyWith method
Implementation
Instrument copyWith({
String? id,
PaymentMethod? type,
String? fingerprint,
int? expiryMonth,
int? expiryYear,
String? last4,
String? bin,
String? scheme,
bool? isDefault,
}) {
return Instrument(
id: id ?? this.id,
type: type ?? this.type,
fingerprint: fingerprint ?? this.fingerprint,
expiryMonth: expiryMonth ?? this.expiryMonth,
expiryYear: expiryYear ?? this.expiryYear,
last4: last4 ?? this.last4,
bin: bin ?? this.bin,
scheme: scheme ?? this.scheme,
isDefault: isDefault ?? this.isDefault,
);
}