From 3e8f9409ae068582f1038d827e6a48e5e04f7a3f Mon Sep 17 00:00:00 2001 From: Peter Anyaogu Date: Fri, 5 Jan 2024 10:25:23 +0100 Subject: [PATCH] hot fix 2: dev n tell --- lib/src/common/contract.dart | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/src/common/contract.dart b/lib/src/common/contract.dart index 1fae22c..86c3b03 100644 --- a/lib/src/common/contract.dart +++ b/lib/src/common/contract.dart @@ -170,7 +170,7 @@ class Contract { Uint8List? innerCallData}) { final params = [ to, - amount ?? EtherAmount.zero().getInWei, + amount?.getInWei ?? EtherAmount.zero().getInWei, innerCallData ?? Uint8List.fromList([]) ]; @@ -197,8 +197,8 @@ class Contract { List? innerCalls}) { final params = [ recipients, - amounts ?? [], - innerCalls ?? [], + amounts?.map((e) => e.getInWei) ?? [], + innerCalls ?? Uint8List.fromList([]), ]; if (innerCalls == null || innerCalls.isEmpty) { require(amounts != null && amounts.isNotEmpty, "malformed batch request");