diff options
author | Özgür Kesim <oec-taler@kesim.org> | 2023-09-09 07:34:11 +0200 |
---|---|---|
committer | Özgür Kesim <oec-taler@kesim.org> | 2023-09-09 07:34:11 +0200 |
commit | 5495551071a3fdc36c38deb4c1cf6f4aa5b98bd4 (patch) | |
tree | adf7730b190618a0499e50a2d43cf1b850cddd16 /packages/taler-wallet-core/src/operations/pay-peer-common.ts | |
parent | 94cfcc875065f988815c31aaf8ebf36f75ac5983 (diff) | |
parent | 6c3cfa9be7a332c2cc8490f25ebd6c73c8244842 (diff) |
Merge branch 'master' into age-withdraw
Diffstat (limited to 'packages/taler-wallet-core/src/operations/pay-peer-common.ts')
-rw-r--r-- | packages/taler-wallet-core/src/operations/pay-peer-common.ts | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/packages/taler-wallet-core/src/operations/pay-peer-common.ts b/packages/taler-wallet-core/src/operations/pay-peer-common.ts index 9e05e43d8..6d425289d 100644 --- a/packages/taler-wallet-core/src/operations/pay-peer-common.ts +++ b/packages/taler-wallet-core/src/operations/pay-peer-common.ts @@ -108,16 +108,8 @@ export async function getTotalPeerPaymentCost( } const allDenoms = await tx.denominations.indexes.byExchangeBaseUrl .iter(coin.exchangeBaseUrl) - .filter((x) => - Amounts.isSameCurrency( - DenominationRecord.getValue(x), - pcs[i].contribution, - ), - ); - const amountLeft = Amounts.sub( - DenominationRecord.getValue(denom), - pcs[i].contribution, - ).amount; + .filter((x) => Amounts.isSameCurrency(x.value, pcs[i].contribution)); + const amountLeft = Amounts.sub(denom.value, pcs[i].contribution).amount; const refreshCost = getTotalRefreshCost( allDenoms, DenominationRecord.toDenomInfo(denom), |