mirror of
https://github.com/trezor/trezor-wallet
synced 2024-11-24 09:18:09 +00:00
fix: calculate pending amount
This commit is contained in:
parent
46c1f8b2b7
commit
47af92ae2c
@ -100,7 +100,7 @@ export const getPendingNonce = (pending: Array<PendingTx>): number => {
|
||||
export const getPendingAmount = (pending: Array<PendingTx>, currency: string): BigNumber => {
|
||||
return pending.reduce((value: BigNumber, tx: PendingTx) => {
|
||||
if (tx.currency === currency) {
|
||||
return new BigNumber(value).plus(tx.amount);
|
||||
return new BigNumber(value).plus(tx.total);
|
||||
}
|
||||
return value;
|
||||
}, new BigNumber('0'));
|
||||
|
Loading…
Reference in New Issue
Block a user