mirror of
https://github.com/cypherstack/stack_wallet.git
synced 2024-11-17 01:37:54 +00:00
extra balance getters in firo
This commit is contained in:
parent
d84cde3db6
commit
7a23cfc4d2
1 changed files with 10 additions and 0 deletions
|
@ -1761,6 +1761,8 @@ class FiroWallet extends CoinServiceAPI {
|
||||||
balances.add(
|
balances.add(
|
||||||
(lelantusBalance + utxosValue + _unconfirmedLelantusBalance) * price);
|
(lelantusBalance + utxosValue + _unconfirmedLelantusBalance) * price);
|
||||||
|
|
||||||
|
balances.add(utxosValue);
|
||||||
|
|
||||||
Logging.instance.log("balances $balances", level: LogLevel.Info);
|
Logging.instance.log("balances $balances", level: LogLevel.Info);
|
||||||
await DB.instance.put<dynamic>(
|
await DB.instance.put<dynamic>(
|
||||||
boxName: walletId,
|
boxName: walletId,
|
||||||
|
@ -3884,4 +3886,12 @@ class FiroWallet extends CoinServiceAPI {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Future<Decimal> availablePrivateBalance() async {
|
||||||
|
return (await balances)[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
Future<Decimal> availablePublicBalance() async {
|
||||||
|
return (await balances)[4];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue