From 9b139376d7220fcbf81fe65454fcb2dc7f169d75 Mon Sep 17 00:00:00 2001 From: Terry Li Date: Fri, 20 Sep 2024 00:25:21 -0700 Subject: [PATCH] Staging (#2271) * fhenix new * add error message --- wondrous-bot-admin/src/services/web3/useWeb3Auth.tsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/wondrous-bot-admin/src/services/web3/useWeb3Auth.tsx b/wondrous-bot-admin/src/services/web3/useWeb3Auth.tsx index 4a562c2aa..874acf406 100644 --- a/wondrous-bot-admin/src/services/web3/useWeb3Auth.tsx +++ b/wondrous-bot-admin/src/services/web3/useWeb3Auth.tsx @@ -181,6 +181,12 @@ const useWeb3Auth = ({ setErrorMessage }) => { setIsActivating(false); disconnect(); } + if (result === 'Wallet already connected'){ + setErrorMessage('Wallet is already connected to another account'); + onFail(); + setIsActivating(false); + disconnect(); + } } else if (!signedMessageIsString(signedMessage)) { setIsActivating(false); setErrorMessage("Signature rejected. Try again.");