mirror of
https://github.com/koreanbots/core.git
synced 2025-12-15 14:10:22 +00:00
chore: prevent caching logout endpoint
This commit is contained in:
parent
1453a8e4bd
commit
6de13b0892
@ -5,6 +5,7 @@ import { serialize } from 'cookie'
|
||||
|
||||
const Logout = nc<NextApiRequest, NextApiResponse>()
|
||||
.get(async(req, res) => {
|
||||
res.setHeader('Cache-control', 'no-cache')
|
||||
res.setHeader('set-cookie', serialize('token', '', {
|
||||
maxAge: -1,
|
||||
path: '/'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user