We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e99f0a0 commit 3c6b10bCopy full SHA for 3c6b10b
src/helpers/redirects.ts
@@ -18,7 +18,7 @@ const generateLocaleRedirects = ({
18
const redirects: NetlifyConfig['redirects'] = []
19
// If the cookie is set, we need to redirect at the origin
20
redirects.push({
21
- from: `${basePath}${trailingSlash ? '/' : ''}`,
+ from: `${basePath}/`,
22
to: HANDLER_FUNCTION_PATH,
23
status: 200,
24
force: true,
@@ -32,7 +32,7 @@ const generateLocaleRedirects = ({
32
}
33
34
from: `${basePath}/`,
35
- to: `${basePath}/${locale}/`,
+ to: `${basePath}/${locale}${trailingSlash ? '/' : ''}`,
36
status: 301,
37
conditions: {
38
Language: [locale],
0 commit comments