diff options
Diffstat (limited to 'packages/taler-wallet-webextension/src/wallet')
-rw-r--r-- | packages/taler-wallet-webextension/src/wallet/DeveloperPage.stories.tsx | 1 | ||||
-rw-r--r-- | packages/taler-wallet-webextension/src/wallet/Transaction.tsx | 9 |
2 files changed, 3 insertions, 7 deletions
diff --git a/packages/taler-wallet-webextension/src/wallet/DeveloperPage.stories.tsx b/packages/taler-wallet-webextension/src/wallet/DeveloperPage.stories.tsx index 1a5d72337..ae1581009 100644 --- a/packages/taler-wallet-webextension/src/wallet/DeveloperPage.stories.tsx +++ b/packages/taler-wallet-webextension/src/wallet/DeveloperPage.stories.tsx @@ -35,6 +35,7 @@ export const AllOff = createExample(TestedComponent, { onDownloadDatabase: async () => "this is the content of the database", operations: [ { + id: "", type: PendingTaskType.ExchangeUpdate, exchangeBaseUrl: "http://exchange.url.", givesLifeness: false, diff --git a/packages/taler-wallet-webextension/src/wallet/Transaction.tsx b/packages/taler-wallet-webextension/src/wallet/Transaction.tsx index 3d2a16e8f..21cee8789 100644 --- a/packages/taler-wallet-webextension/src/wallet/Transaction.tsx +++ b/packages/taler-wallet-webextension/src/wallet/Transaction.tsx @@ -70,13 +70,8 @@ interface Props { } async function getTransaction(tid: string): Promise<Transaction> { - const res = await wxApi.getTransactions(); - const ts = res.transactions.filter((t) => t.transactionId === tid); - if (ts.length > 1) throw Error("more than one transaction with this id"); - if (ts.length === 1) { - return ts[0]; - } - throw Error("no transaction found"); + const res = await wxApi.getTransactionById(tid); + return res; } export function TransactionPage({ tid, goToWalletHistory }: Props): VNode { |