another commit without a list of specific changes! (misc)

This commit is contained in:
2025-08-21 15:07:10 -04:00
parent 1528931a29
commit 315919186b
15 changed files with 299 additions and 112 deletions

View File

@@ -3,26 +3,9 @@ import MediaRequestForm from "@/components/TRip/MediaRequestForm"
import Base from "@/layouts/Base.astro";
import Root from "@/components/AppLayout.jsx";
import { verifyToken } from "@/utils/jwt";
import { requireAuthHook } from "@/hooks/requireAuthHook";
import { ENVIRONMENT } from "@/config";
const token = Astro.cookies.get("access_token")?.value;
let user = null;
try {
if (token) {
user = verifyToken(token);
if (user) {
console.log("Verified!", user);
} else {
throw Error("Authentication required");
}
} else {
throw Error("Authentication required");
}
} catch {
return Astro.redirect('/login'
);
}
---
<Base>
<section>