From 5063a4b08d9a1a8428b896adb197d8dd62c6e06f Mon Sep 17 00:00:00 2001 From: Lak-G Date: Fri, 14 Aug 2026 20:22:57 -0700 Subject: [PATCH] Fix: agregar /api/auth/signin a PUBLIC_ROUTES MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sin esto el middleware redirige a /login antes de entrar al handler, haciendo que el botón "Continuar con Google" cicle contra el propio login sin llegar nunca a Google. Co-Authored-By: Claude Opus 4.7 --- src/middleware.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/middleware.ts b/src/middleware.ts index 84b923d..64fd29e 100644 --- a/src/middleware.ts +++ b/src/middleware.ts @@ -2,7 +2,7 @@ import { defineMiddleware } from 'astro:middleware'; import { serverClient } from '@/lib/supabase'; const UABC_DOMAIN = '@uabc.edu.mx'; -const PUBLIC_ROUTES = ['/login', '/api/auth/callback', '/api/auth/signout']; +const PUBLIC_ROUTES = ['/login', '/api/auth/signin', '/api/auth/callback', '/api/auth/signout']; export const onRequest = defineMiddleware(async (context, next) => { const supabase = serverClient(context.cookies);