check for existing user on remount

This commit is contained in:
2026-06-08 12:40:52 +02:00
parent d1cdc7764b
commit 430ec2db75
4 changed files with 41 additions and 8 deletions
+1 -1
View File
@@ -3,7 +3,7 @@ import { useLichessOAuth } from "#/hooks/useLichessOAuth.ts";
const LichessButton = () => {
const { lichessLogin, lichessLogout } = useLichessOAuth();
const { user, setUser, logout } = useLichessUser();
const { user } = useLichessUser();
const onClickHandler = () => {
return user?.isLoggedIn ? lichessLogout() : lichessLogin();