From 1ceef3f11cc25202bbfc92a303f72cdab1a4ceeb Mon Sep 17 00:00:00 2001 From: Mayne0213 Date: Sat, 10 Jan 2026 02:48:30 +0900 Subject: [PATCH] FEAT(jotion): redirect root path to /home - Add redirect from / to /home in middleware - Remove / from publicPaths list --- nextjs/middleware.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/nextjs/middleware.ts b/nextjs/middleware.ts index 670183f..121907c 100644 --- a/nextjs/middleware.ts +++ b/nextjs/middleware.ts @@ -4,9 +4,14 @@ import { verifyToken } from './src/shared/lib/auth' export function middleware(request: NextRequest) { const { pathname } = request.nextUrl + // Redirect root path to /home + if (pathname === '/') { + const url = new URL('/home', request.url) + return NextResponse.redirect(url) + } + // Public paths that don't require authentication const publicPaths = [ - '/', '/home', '/home/signIn', '/home/signUp',