migration to postgres

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-26 17:42:59 +00:00
co-authored by Claude Opus 4.6
parent 7f04ecd644
commit 500a70910e
54 changed files with 4016 additions and 264 deletions
+2 -2
View File
@@ -50,7 +50,7 @@ const devServerWebsocket = {
try {
const payload = await verify(wsToken);
if (!payload) { ws.close(4001, 'Unauthorized'); return; }
if (payload.jti && isTokenBlacklisted(payload.jti)) { ws.close(4001, 'Unauthorized'); return; }
if (payload.jti && await isTokenBlacklisted(payload.jti)) { ws.close(4001, 'Unauthorized'); return; }
} catch {
ws.close(4001, 'Unauthorized');
return;
@@ -108,7 +108,7 @@ async function upgradeWs(req: Request, server: any, provider: 'terminal' | 'pi')
if (!user) return new Response('Unauthorized', { status: 401 });
if (user.jti) {
if (isTokenBlacklisted(user.jti)) return new Response('Unauthorized', { status: 401 });
if (await isTokenBlacklisted(user.jti)) return new Response('Unauthorized', { status: 401 });
}
const url = new URL(req.url);