aboutsummaryrefslogtreecommitdiff
path: root/packages/taler-wallet-webextension/src/cta/Withdraw/state.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/taler-wallet-webextension/src/cta/Withdraw/state.ts')
-rw-r--r--packages/taler-wallet-webextension/src/cta/Withdraw/state.ts11
1 files changed, 5 insertions, 6 deletions
diff --git a/packages/taler-wallet-webextension/src/cta/Withdraw/state.ts b/packages/taler-wallet-webextension/src/cta/Withdraw/state.ts
index c2b9e375f..53bac579e 100644
--- a/packages/taler-wallet-webextension/src/cta/Withdraw/state.ts
+++ b/packages/taler-wallet-webextension/src/cta/Withdraw/state.ts
@@ -182,16 +182,15 @@ function exchangeSelectionState(
* about the withdrawal
*/
const amountHook = useAsyncAsHook(async () => {
- const info = await api.getExchangeWithdrawalInfo({
+ const info = await api.getWithdrawalDetailsForAmount({
exchangeBaseUrl: currentExchange.exchangeBaseUrl,
- amount: chosenAmount,
- tosAcceptedFormat: ["text/xml"],
- ageRestricted,
+ amount: Amounts.stringify(chosenAmount),
+ restrictAge: ageRestricted,
});
const withdrawAmount = {
- raw: Amounts.parseOrThrow(info.withdrawalAmountRaw),
- effective: Amounts.parseOrThrow(info.withdrawalAmountEffective),
+ raw: Amounts.parseOrThrow(info.amountRaw),
+ effective: Amounts.parseOrThrow(info.amountEffective),
};
return {