Skip to content

Commit

Permalink
[sitecore-jss-nextjs] #607601: redirects middleware has been fixed w…
Browse files Browse the repository at this point in the history
…hen pattern has locale and target is absolute url
  • Loading branch information
Rmatkovsky committed Feb 14, 2024
1 parent e2409b3 commit 845c621
Showing 1 changed file with 0 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,6 @@ export class RedirectsMiddleware extends MiddlewareBase {

if (REGEXP_ABSOLUTE_URL.test(existsRedirect.target)) {
url.href = existsRedirect.target;
url.locale = req.nextUrl.locale;
} else {
const source = `${url.pathname}${url.search}`;
url.search = existsRedirect.isQueryStringPreserved ? url.search : '';
Expand Down

0 comments on commit 845c621

Please sign in to comment.