Skip to content

Conversation

@brophdawg11
Copy link
Contributor

Fixes a small 1.10.0 regression in same-origin absolute redirects

Former Remix logic: https://github.com/remix-run/remix/blob/%40remix-run/serve%401.7.6/packages/remix-react/routes.tsx#L227

Closes: remix-run/remix#5117

@changeset-bot
Copy link

changeset-bot bot commented Jan 17, 2023

🦋 Changeset detected

Latest commit: ee88edf

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 5 packages
Name Type
@remix-run/router Patch
react-router Patch
react-router-dom Patch
react-router-dom-v5-compat Patch
react-router-native Patch

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


// Check if this an external redirect that goes to a new origin
if (typeof window?.location !== "undefined") {
if (isBrowser && typeof window?.location !== "undefined") {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ensure in-memory routers don't try this window check

@brophdawg11 brophdawg11 merged commit bf46fb6 into release-next Jan 17, 2023
@brophdawg11 brophdawg11 deleted the brophdawg11/same-origin-absolute-redirects branch January 17, 2023 18:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants