-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[next]: fix defaultLocale redirect when using domains pattern #12166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
🦋 Changeset detectedLatest commit: f93fddf The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
ijjk
reviewed
Sep 24, 2024
ijjk
reviewed
Sep 24, 2024
ijjk
reviewed
Sep 24, 2024
ijjk
reviewed
Sep 24, 2024
Co-authored-by: JJ Kasper <jj@jjsweb.site>
Co-authored-by: JJ Kasper <jj@jjsweb.site>
ijjk
approved these changes
Sep 24, 2024
Merged
trek
pushed a commit
that referenced
this pull request
Sep 26, 2024
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## vercel@37.6.0 ### Minor Changes - [cli] remove `textInput` in favor of `input.text` ([#12168](#12168)) - Add stub telemetry behavior in preparation for use tracking ([#12173](#12173)) ### Patch Changes - Introduce new chain configuration for Partial Prerendering ([#12117](#12117)) - [cli] correctly call to create new deployment when promoting preview deployment ([#12178](#12178)) - Updated dependencies \[[`42ae831561365b8254e62cf57f41caca03af4c31`](42ae831), [`62f434a79fe25009e63fcaefda0abe283c590f58`](62f434a), [`37ec6fa7f5ff313bfdb22570fb33f8b7eff280e6`](37ec6fa)]: - @vercel/next@4.3.11 - @vercel/build-utils@8.4.5 - @vercel/node@3.2.17 - @vercel/static-build@2.5.27 ## @vercel/build-utils@8.4.5 ### Patch Changes - [build-utils] add types for `images.remotePatterns.search` to vercel.json ([#12158](#12158)) ## @vercel/client@13.4.9 ### Patch Changes - Updated dependencies \[[`62f434a79fe25009e63fcaefda0abe283c590f58`](62f434a)]: - @vercel/build-utils@8.4.5 ## @vercel/gatsby-plugin-vercel-builder@2.0.49 ### Patch Changes - Updated dependencies \[[`62f434a79fe25009e63fcaefda0abe283c590f58`](62f434a)]: - @vercel/build-utils@8.4.5 ## @vercel/next@4.3.11 ### Patch Changes - Introduce new chain configuration for Partial Prerendering ([#12117](#12117)) - fix defaultLocale redirect when using domains pattern ([#12166](#12166)) ## @vercel/node@3.2.17 ### Patch Changes - Updated dependencies \[[`62f434a79fe25009e63fcaefda0abe283c590f58`](62f434a)]: - @vercel/build-utils@8.4.5 ## @vercel/static-build@2.5.27 ### Patch Changes - Updated dependencies \[]: - @vercel/gatsby-plugin-vercel-builder@2.0.49 ## @vercel-internals/types@2.0.9 ### Patch Changes - Updated dependencies \[[`62f434a79fe25009e63fcaefda0abe283c590f58`](62f434a)]: - @vercel/build-utils@8.4.5 Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
QuietCraftsmanship
pushed a commit
to QuietCraftsmanship/Vercel
that referenced
this pull request
Jul 6, 2025
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. # Releases ## vercel@37.6.0 ### Minor Changes - [cli] remove `textInput` in favor of `input.text` ([#12168](vercel/vercel#12168)) - Add stub telemetry behavior in preparation for use tracking ([#12173](vercel/vercel#12173)) ### Patch Changes - Introduce new chain configuration for Partial Prerendering ([#12117](vercel/vercel#12117)) - [cli] correctly call to create new deployment when promoting preview deployment ([#12178](vercel/vercel#12178)) - Updated dependencies \[[`3783b78fafbfbb654351f1e1c270a5daf26275bc`](vercel/vercel@3783b78), [`d7771d7c652a889402ca89c5e617fc3b44638a12`](vercel/vercel@d7771d7), [`d79a681bd7d2bb277c615ba07db02dd86be08bd3`](vercel/vercel@d79a681)]: - @vercel/next@4.3.11 - @vercel/build-utils@8.4.5 - @vercel/node@3.2.17 - @vercel/static-build@2.5.27 ## @vercel/build-utils@8.4.5 ### Patch Changes - [build-utils] add types for `images.remotePatterns.search` to vercel.json ([#12158](vercel/vercel#12158)) ## @vercel/client@13.4.9 ### Patch Changes - Updated dependencies \[[`d7771d7c652a889402ca89c5e617fc3b44638a12`](vercel/vercel@d7771d7)]: - @vercel/build-utils@8.4.5 ## @vercel/gatsby-plugin-vercel-builder@2.0.49 ### Patch Changes - Updated dependencies \[[`d7771d7c652a889402ca89c5e617fc3b44638a12`](vercel/vercel@d7771d7)]: - @vercel/build-utils@8.4.5 ## @vercel/next@4.3.11 ### Patch Changes - Introduce new chain configuration for Partial Prerendering ([#12117](vercel/vercel#12117)) - fix defaultLocale redirect when using domains pattern ([#12166](vercel/vercel#12166)) ## @vercel/node@3.2.17 ### Patch Changes - Updated dependencies \[[`d7771d7c652a889402ca89c5e617fc3b44638a12`](vercel/vercel@d7771d7)]: - @vercel/build-utils@8.4.5 ## @vercel/static-build@2.5.27 ### Patch Changes - Updated dependencies \[]: - @vercel/gatsby-plugin-vercel-builder@2.0.49 ## @vercel-internals/types@2.0.9 ### Patch Changes - Updated dependencies \[[`d7771d7c652a889402ca89c5e617fc3b44638a12`](vercel/vercel@d7771d7)]: - @vercel/build-utils@8.4.5 Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The redirect rule for
defaultLocaleis incorrectly matching the/indexroute resulting in a intermediary rewrite to/<locale>/index, which then falls through to the trailing slash redirect. This causes a 308 to the default locale for the domain even though the user would already be on the correct path.This splits the existing
$wildcard/$1handling into two separate routes, one for the index route and another for everything else, so that it is handled properly.This cannot be tested as it requires assigning a domain. However, I validated this fixes it in this deployment.