I am wonfident this will work

This commit is contained in:
2025-02-02 17:41:06 -06:00
parent 63fd47a025
commit f675814b34

View File

@ -9,6 +9,9 @@ export const POST: APIRoute = async ({ request }) => {
const { code } = await request.json(); const { code } = await request.json();
const secretCode = process.env.SECRET_CODE || import.meta.env.SECRET_CODE; const secretCode = process.env.SECRET_CODE || import.meta.env.SECRET_CODE;
console.log("Received code:", code); // For debugging
console.log("Secret code:", secretCode); // For debugging
if (!code || code !== secretCode) { if (!code || code !== secretCode) {
return new Response( return new Response(
JSON.stringify({ JSON.stringify({