From 084f84b1bd918fa3606e50e9423af681c4a7af79 Mon Sep 17 00:00:00 2001 From: Mark Spanbroek Date: Mon, 22 Mar 2021 15:50:57 +0100 Subject: [PATCH] Fix compilation error in Nim 1.2.6 --- nitro/wallet/wallet.nim | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/nitro/wallet/wallet.nim b/nitro/wallet/wallet.nim index b499e11..2a9c6c7 100644 --- a/nitro/wallet/wallet.nim +++ b/nitro/wallet/wallet.nim @@ -108,9 +108,12 @@ func balance*(wallet: Wallet, func balance*(wallet: Wallet, channel: ChannelId, asset: EthAddress, - address = wallet.address): UInt256 = + address: EthAddress): UInt256 = wallet.balance(channel, asset, address.toDestination) +func balance*(wallet: Wallet, channel: ChannelId, asset: EthAddress): UInt256 = + wallet.balance(channel, asset, wallet.address) + func total(state: State, asset: EthAddress): UInt256 = var total: UInt256 if balances =? state.outcome.balances(asset):