aboutsummaryrefslogtreecommitdiff
path: root/src/wallet.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2019-09-01 22:59:48 +0200
committerFlorian Dold <florian.dold@gmail.com>2019-09-01 22:59:48 +0200
commit82591a9ba9751336480ab429886c085786172ec4 (patch)
tree324eba13db4a9e055a0c79660ae159b1649755f5 /src/wallet.ts
parent4fd092e7e3c060b8b027e16e44f26cce5fd8c0e8 (diff)
don't show wrong balance
Diffstat (limited to 'src/wallet.ts')
-rw-r--r--src/wallet.ts3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/wallet.ts b/src/wallet.ts
index 1d231f2df..14ab45444 100644
--- a/src/wallet.ts
+++ b/src/wallet.ts
@@ -2230,10 +2230,13 @@ export class Wallet {
if (!r.timestamp_confirmed) {
return balance;
}
+ let amount = Amounts.getZero(r.requested_amount.currency);
+ /*
let amount = r.current_amount;
if (!amount) {
amount = r.requested_amount;
}
+ */
amount = Amounts.add(amount, r.precoin_amount).amount;
if (Amounts.cmp(smallestWithdraw[r.exchange_base_url], amount) < 0) {
addTo(balance, "pendingIncoming", amount, r.exchange_base_url);