fix(striker-ui-api): move user to session cookie

main
Tsu-ba-me 1 year ago
parent 34bd441c83
commit 0fad937554
  1. 2
      striker-ui-api/src/lib/request_handlers/auth/login.ts
  2. 1
      striker-ui-api/src/lib/request_handlers/auth/logout.ts

@ -16,8 +16,8 @@ export const login: RequestHandler<unknown, unknown, AuthLoginRequestBody> = (
response.cookie(cname('session'), {
expires: session?.cookie?.expires,
user,
});
response.cookie(cname('user'), user);
}
response.status(204).send();

@ -13,7 +13,6 @@ export const logout: RequestHandler = (request, response) => {
response.clearCookie(cname('session'));
response.clearCookie(cname('sid'));
response.clearCookie(cname('user'));
return response.status(204).send();
});

Loading…
Cancel
Save