Skip to content

Commit

Permalink
updated the keypair generation mechanism to use user signatures inste…
Browse files Browse the repository at this point in the history
…ad of storing the keys in the localstorage
  • Loading branch information
yashgo0018 committed Apr 27, 2024
1 parent 78fa5d7 commit 7727656
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/nextjs/contexts/AuthContext.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ export default function AuthContextProvider({ children }: { children: React.Reac
}, []);

useEffect(() => {
if (!address) {
if (!address || !signMessage) {
setKeyPair(null);
return;
}

signMessage();
}, [address]);
}, [address, signMessage]);

useEffect(() => {
if (!signature) return;
Expand Down

0 comments on commit 7727656

Please sign in to comment.