diff options
author | Sebastian <sebasjm@gmail.com> | 2022-01-04 17:06:17 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2022-01-04 17:06:24 -0300 |
commit | 9f8139e09b21ec12f9b9ba4926ea80557698c559 (patch) | |
tree | dba5aacf50e89176bee35cfdd1002cc61c3f52e5 /packages/taler-wallet-webextension/src/wallet/DepositPage.tsx | |
parent | 2e71117f59e0ae6106930e705ae6a54a9839281b (diff) | |
download | wallet-core-9f8139e09b21ec12f9b9ba4926ea80557698c559.tar.xz |
replace jest with mocha
Diffstat (limited to 'packages/taler-wallet-webextension/src/wallet/DepositPage.tsx')
-rw-r--r-- | packages/taler-wallet-webextension/src/wallet/DepositPage.tsx | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/packages/taler-wallet-webextension/src/wallet/DepositPage.tsx b/packages/taler-wallet-webextension/src/wallet/DepositPage.tsx index d4759c537..5c931394d 100644 --- a/packages/taler-wallet-webextension/src/wallet/DepositPage.tsx +++ b/packages/taler-wallet-webextension/src/wallet/DepositPage.tsx @@ -108,8 +108,13 @@ export function View({ const currency = balance.currency; const amountStr: AmountString = `${currency}:${amount}`; - const account = knownBankAccounts[accountIdx]; - const accountURI = `payto://${account.targetType}/${account.targetPath}`; + const account = knownBankAccounts.length + ? knownBankAccounts[accountIdx] + : undefined; + const accountURI = !account + ? "" + : `payto://${account.targetType}/${account.targetPath}`; + useEffect(() => { if (amount === undefined) return; onCalculateFee(accountURI, amountStr).then((result) => { |