diff options
Diffstat (limited to 'packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts')
-rw-r--r-- | packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts b/packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts index ee839cad7..0a66dc381 100644 --- a/packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts +++ b/packages/taler-wallet-webextension/src/wallet/ExchangeSelection/state.ts @@ -15,7 +15,10 @@ */ import { DenomOperationMap, FeeDescription } from "@gnu-taler/taler-util"; -import { createPairTimeline, WalletApiOperation } from "@gnu-taler/taler-wallet-core"; +import { + createPairTimeline, + WalletApiOperation, +} from "@gnu-taler/taler-wallet-core"; import { useState } from "preact/hooks"; import { useAsyncAsHook } from "../../hooks/useAsyncAsHook.js"; import { wxApi } from "../../wxApi.js"; @@ -41,15 +44,23 @@ export function useComponentState( exchanges.length == 0 ? undefined : exchanges[selectedIdx]; const selected = !selectedExchange ? undefined - : await api.wallet.call(WalletApiOperation.GetExchangeDetailedInfo, { exchangeBaseUrl: selectedExchange.exchangeBaseUrl }); + : await api.wallet.call(WalletApiOperation.GetExchangeDetailedInfo, { + exchangeBaseUrl: selectedExchange.exchangeBaseUrl, + }); const initialExchange = selectedIdx === initialValue ? undefined : exchanges[initialValue]; const original = !initialExchange ? undefined - : await api.wallet.call(WalletApiOperation.GetExchangeDetailedInfo, { exchangeBaseUrl: initialExchange.exchangeBaseUrl }); + : await api.wallet.call(WalletApiOperation.GetExchangeDetailedInfo, { + exchangeBaseUrl: initialExchange.exchangeBaseUrl, + }); - return { exchanges, selected: selected?.exchange, original: original?.exchange }; + return { + exchanges, + selected: selected?.exchange, + original: original?.exchange, + }; }, [value]); const [showingTos, setShowingTos] = useState<string | undefined>(undefined); |