mirror of
https://github.com/fosrl/pangolin.git
synced 2025-08-18 08:18:43 +02:00
allow logout to fail
This commit is contained in:
parent
d070415515
commit
58a084426b
1 changed files with 6 additions and 1 deletions
|
@ -30,8 +30,13 @@ export async function logout(
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
try {
|
try {
|
||||||
await invalidateSession(session.sessionId);
|
await invalidateSession(session.sessionId);
|
||||||
|
} catch (error) {
|
||||||
|
logger.error("Failed to invalidate session", error)
|
||||||
|
}
|
||||||
|
|
||||||
const isSecure = req.protocol === "https";
|
const isSecure = req.protocol === "https";
|
||||||
res.setHeader("Set-Cookie", createBlankSessionTokenCookie(isSecure));
|
res.setHeader("Set-Cookie", createBlankSessionTokenCookie(isSecure));
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue