9 lines
324 B
TypeScript
9 lines
324 B
TypeScript
import { NextResponse } from 'next/server'
|
|
import { cookies } from 'next/headers'
|
|
|
|
export async function POST() {
|
|
const cookieStore = await cookies()
|
|
cookieStore.set('tlyq_session', '', { maxAge: 0, path: '/' })
|
|
return NextResponse.redirect(new URL('/login', process.env.NEXT_PUBLIC_URL || 'http://localhost:6179'))
|
|
}
|