summaryrefslogtreecommitdiff
path: root/frontend/app/api/logout/route.ts
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/app/api/logout/route.ts')
-rw-r--r--frontend/app/api/logout/route.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/frontend/app/api/logout/route.ts b/frontend/app/api/logout/route.ts
index 51de324..202a8b7 100644
--- a/frontend/app/api/logout/route.ts
+++ b/frontend/app/api/logout/route.ts
@@ -10,7 +10,7 @@ export async function POST(request: NextRequest) {
10 10
11 if (sessionCookie) { 11 if (sessionCookie) {
12 // Call tinyauth logout endpoint to invalidate the session 12 // Call tinyauth logout endpoint to invalidate the session
13 const logoutResponse = await fetch(`${Auth_tinyauth_endpoint()}/auth/logout`, { 13 await fetch(`${Auth_tinyauth_endpoint()}/auth/logout`, {
14 method: 'POST', 14 method: 'POST',
15 headers: { 15 headers: {
16 'Cookie': `${sessionCookie.name}=${sessionCookie.value}` 16 'Cookie': `${sessionCookie.name}=${sessionCookie.value}`
@@ -29,4 +29,4 @@ export async function POST(request: NextRequest) {
29 // Even if logout fails, redirect to home 29 // Even if logout fails, redirect to home
30 return redirect('/'); 30 return redirect('/');
31 } 31 }
32} \ No newline at end of file 32}