From c809824889fbec90d4ee3737c2b300908166fb59 Mon Sep 17 00:00:00 2001 From: Sohan Rout Date: Sun, 28 Sep 2025 21:53:18 +0530 Subject: [PATCH] Fix : auth route fixed --- app/login/page.jsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/login/page.jsx b/app/login/page.jsx index fc16267..c0a7978 100644 --- a/app/login/page.jsx +++ b/app/login/page.jsx @@ -44,7 +44,7 @@ export default function LoginPage() { if (isLogin) { // Verify captcha first via API route - const verifyRes = await fetch('/auth', { + const verifyRes = await fetch('/api/auth', { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ email, password, captchaToken, action: 'login' }), @@ -59,7 +59,7 @@ export default function LoginPage() { router.push('/dashboard') } else { // Signup flow remains the same - const res = await fetch('/auth', { + const res = await fetch('/api/auth', { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify({ email, password, captchaToken, action: 'signup' }),