fix(frontend): save token to legacy 'token' key for backward compatibility
This commit is contained in:
parent
3fc701a98c
commit
37512a7d1c
1 changed files with 1 additions and 0 deletions
|
|
@ -64,6 +64,7 @@ export async function login(
|
|||
if (typeof window !== "undefined") {
|
||||
localStorage.setItem(AUTH_KEY, JSON.stringify(user));
|
||||
localStorage.setItem("auth_token", data.token);
|
||||
localStorage.setItem("token", data.token); // Legacy support
|
||||
}
|
||||
|
||||
return user;
|
||||
|
|
|
|||
Loading…
Reference in a new issue