From f93bd51499ed34844b666bf6d333227adf4368bf Mon Sep 17 00:00:00 2001
From: Sebastian <sebasjm@gmail.com>
Date: Thu, 15 Dec 2022 17:11:24 -0300
Subject: wxApi from context and using the new testing sdk

---
 packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx')

diff --git a/packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx b/packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx
index d5f072828..eb86c9a3f 100644
--- a/packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx
+++ b/packages/taler-wallet-webextension/src/wallet/ProviderAddPage.tsx
@@ -31,10 +31,10 @@ import {
   SubTitle,
   Title,
 } from "../components/styled/index.js";
+import { useBackendContext } from "../context/backend.js";
 import { useTranslationContext } from "../context/translation.js";
 import { Button } from "../mui/Button.js";
 import { queryToSlashConfig } from "../utils/index.js";
-import { wxApi } from "../wxApi.js";
 
 interface Props {
   currency: string;
@@ -46,7 +46,7 @@ export function ProviderAddPage({ onBack }: Props): VNode {
     | { url: string; name: string; provider: BackupBackupProviderTerms }
     | undefined
   >(undefined);
-
+  const api = useBackendContext();
   if (!verifying) {
     return (
       <SetUrlView
@@ -70,7 +70,7 @@ export function ProviderAddPage({ onBack }: Props): VNode {
         setVerifying(undefined);
       }}
       onConfirm={() => {
-        return wxApi.wallet
+        return api.wallet
           .call(WalletApiOperation.AddBackupProvider, {
             backupProviderBaseUrl: verifying.url,
             name: verifying.name,
-- 
cgit v1.2.3

