Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
alan2207 committed May 3, 2024
1 parent 7bf605e commit 79ff534
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/test/server/handlers/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ export const authHandlers = [
return HttpResponse.json(result, {
headers: {
// with a real API servier, the token cookie should also be Secure and HttpOnly
'Set-Cookie': `${AUTH_COOKIE}=${result.jwt}; Path=/; Max-Age=3600;`,
'Set-Cookie': `${AUTH_COOKIE}=${result.jwt};`,
},
});
} catch (error: any) {
Expand All @@ -101,7 +101,7 @@ export const authHandlers = [
return HttpResponse.json(result, {
headers: {
// with a real API servier, the token cookie should also be Secure and HttpOnly
'Set-Cookie': `${AUTH_COOKIE}=${result.jwt}; Path=/; Max-Age=3600;`,
'Set-Cookie': `${AUTH_COOKIE}=${result.jwt};`,
},
});
} catch (error: any) {
Expand All @@ -114,7 +114,7 @@ export const authHandlers = [
{ message: 'Logged out' },
{
headers: {
'Set-Cookie': `${AUTH_COOKIE}=; Path=/; Max-Age=0;`,
'Set-Cookie': `${AUTH_COOKIE}=;`,
},
}
);
Expand Down

0 comments on commit 79ff534

Please sign in to comment.