Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
hide-on-bush-x committed Feb 16, 2023
1 parent b49d6cd commit 7b842e6
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/provider/modules/session/session.ts
Expand Up @@ -22,6 +22,15 @@ export const useSession = (
return ['session-data', walletAddress];
}, [walletAddress]);

const { data: session } = useQuery(
queryKeySession,
() => masa?.session.getSession(),
{
enabled: !!masa,
retry: false,
}
);

const {
data: loggedIn,
status,
Expand All @@ -32,15 +41,6 @@ export const useSession = (
retry: false,
});

const { data: session } = useQuery(
queryKeySession,
() => masa?.session.checkLogin(),
{
enabled: !!masa,
retry: false,
}
);

useEffect(() => {
if (session && session.user.address !== walletAddress) {
masa?.session.logout();
Expand Down

0 comments on commit 7b842e6

Please sign in to comment.