chore: update ENV.md for NextAuth URL configuration, remove debug logging from middleware, and adjust session token handling in auth middleware

This commit is contained in:
Julien Froidefond
2025-10-16 23:56:46 +02:00
parent 57a1cb5e46
commit 2c850d1c59
4 changed files with 9 additions and 19 deletions

View File

@@ -40,8 +40,6 @@ export default async function middleware(request: NextRequest) {
// Vérifier l'authentification avec NextAuth v5
const session = await getAuthSession(request);
console.log(`[Middleware] Path: ${pathname}, Has session: ${!!session}`);
if (!session) {
if (pathname.startsWith("/api/")) {
return NextResponse.json(