This commit is contained in:
Michael Freno
2026-01-07 16:22:31 -05:00
parent 041b2f8dc2
commit 0a0c0e313e
15 changed files with 809 additions and 2251 deletions

View File

@@ -1,18 +1,13 @@
import type { APIEvent } from "@solidjs/start/server";
import { getCookie, getEvent, setCookie } from "vinxi/http";
import { getEvent, clearSession } from "vinxi/http";
import { sessionConfig } from "~/server/session-config";
export async function POST() {
"use server";
const event = getEvent()!;
setCookie(event, "userIDToken", "", {
path: "/",
httpOnly: true,
secure: true,
sameSite: "lax",
maxAge: 0,
expires: new Date(0)
});
// Clear Vinxi session
await clearSession(event, sessionConfig);
return new Response(null, {
status: 302,

View File

@@ -1158,8 +1158,7 @@ export default function TestPage() {
<div>
<h3 class="mb-2 text-lg font-semibold">🔴 Admin Required</h3>
<p class="mb-2 text-sm">
Maintenance endpoints require admin privileges (userIDToken
cookie with ADMIN_ID).
Maintenance endpoints require admin privileges.
</p>
<ul class="ml-6 list-disc space-y-1 text-sm">
<li>