mirror of
https://github.com/umami-software/umami.git
synced 2026-02-10 07:37:11 +01:00
Switch to authentication using bearer token.
This commit is contained in:
parent
698d4d2687
commit
d8e831db50
8 changed files with 33 additions and 35 deletions
|
|
@ -1,15 +0,0 @@
|
|||
import { serialize } from 'cookie';
|
||||
import { AUTH_COOKIE_NAME } from 'lib/constants';
|
||||
import { ok } from 'lib/response';
|
||||
|
||||
export default async (req, res) => {
|
||||
const cookie = serialize(AUTH_COOKIE_NAME, '', {
|
||||
path: '/',
|
||||
httpOnly: true,
|
||||
maxAge: 0,
|
||||
});
|
||||
|
||||
res.setHeader('Set-Cookie', [cookie]);
|
||||
|
||||
return ok(res);
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue