From 6778d10d1b8bda104278207ce67a59357b78dfb4 Mon Sep 17 00:00:00 2001 From: Ethan Lee <125412902+ethan-tbd@users.noreply.github.com> Date: Thu, 25 Jul 2024 10:48:59 -0700 Subject: [PATCH] fix: temporarily add `PaymentInstruction` back to `QuoteDetails` (#55) --- lib/src/protocol/models/message_data.dart | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/src/protocol/models/message_data.dart b/lib/src/protocol/models/message_data.dart index a3b6ddb..898e0ce 100644 --- a/lib/src/protocol/models/message_data.dart +++ b/lib/src/protocol/models/message_data.dart @@ -209,12 +209,14 @@ class QuoteDetails { final String subtotal; final String total; final String? fee; + final PaymentInstruction? paymentInstruction; QuoteDetails({ required this.currencyCode, required this.subtotal, required this.total, this.fee, + this.paymentInstruction, }); factory QuoteDetails.fromJson(Map json) { @@ -223,6 +225,9 @@ class QuoteDetails { subtotal: json['subtotal'], total: json['total'], fee: json['fee'], + paymentInstruction: json['paymentInstruction'] != null + ? PaymentInstruction.fromJson(json['paymentInstruction']) + : null, ); } @@ -232,6 +237,8 @@ class QuoteDetails { 'subtotal': subtotal, 'total': total, if (fee != null) 'fee': fee, + if (paymentInstruction != null) + 'paymentInstruction': paymentInstruction?.toJson(), }; } }