From 7fe26676731d9ccb71194f987a45e18aba34ab89 Mon Sep 17 00:00:00 2001 From: MickWang <1244134672@qq.com> Date: Fri, 26 Apr 2024 14:35:05 +0800 Subject: [PATCH] fix rumtime error on okx app --- store/onboard.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/store/onboard.ts b/store/onboard.ts index aac06f751..6d9e361d8 100644 --- a/store/onboard.ts +++ b/store/onboard.ts @@ -142,7 +142,7 @@ export const useOnboardStore = defineStore("onboard", () => { wagmiConnector.value = connector; connectorName.value = connector?.name; let name = ""; - if (connections?.[0]?.connector.getProvider) { + if (connections?.[0]?.connector?.getProvider && typeof connections?.[0]?.connector?.getProvider === "function") { const provider: unknown = await connections?.[0]?.connector.getProvider(); name = provider?.session?.peer?.metadata?.name; } else {