Add result and job management APIs
This commit is contained in:
@@ -245,7 +245,7 @@ function hasValidCsrf(req: Request): boolean {
|
||||
return Boolean(header && cookie && timingSafeEqual(header, cookie));
|
||||
}
|
||||
|
||||
async function isAuthenticated(req: Request): Promise<boolean> {
|
||||
export async function isAuthenticated(req: Request): Promise<boolean> {
|
||||
const auth = parseCookies(req.headers.get("cookie")).get(AUTH_COOKIE);
|
||||
if (auth && await verifyAuthCookie(auth)) return true;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user