ci: a real smoke test for the localized routes, and a single redirect from the root
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
cbf724db2a
commit
3a1a095e97
4 files changed
+78
-7
No files matched your search
+1
-1
@@ -67,7 +67,7 @@ export default function middleware(request) {
|
||||
// 1. Raiz: negociação de idioma (307)
|
||||
if (pathname === "/") {
|
||||
const targetLocale = resolveRootLocale(request);
|
||||
const url = new URL(`/${targetLocale}/`, request.url);
|
||||
const url = new URL(`/${targetLocale}`, request.url);
|
||||
url.search = search;
|
||||
const response = NextResponse.redirect(url, 307);
|
||||
response.headers.set("Vary", "Accept-Language, Cookie");
|
||||
|
||||
Reference in new issue
Block a user