Skip to content
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

[BUG] redirects from hybrid SFCC site error when pathname includes site alias and locale #1064

Closed
sandragolden opened this issue Mar 15, 2023 · 1 comment

Comments

@sandragolden
Copy link
Contributor

Summary

When testing a hybrid app between SFRA/SiteGenesis, certain pages are redirected to PWA. For account pages, if the shopper is not logged in, they are redirected back to the original page via location.state.directedFrom. When the pathname contains the site alias and locale (/RefArch/en-US/account/wishlist), the navigate(location.state.directedFrom) results in a 404 with duplicate site aliases and locales (/RefArch/en-US/RefArch/en-US/account/wishlist)

Steps To Reproduce

  1. Navigate directly to http://localhost:3000/RefArch/en-US/account/wishlist
  2. Login
  3. notice 404 for http://localhost:3000/RefArch/en-US/RefArch/en-US/account/wishlist URL

Expected result

Shopper is redirected to account wishlist page after login

Actual result

404

System Information (as applicable)

Browser: Firefox
Node version: 16.19.1
pwa-kit version: 2.7.0
Desktop OS: macOS
Mobile Device Info: n/a

Additional information

Feel free to attach a screenshot.

@sandragolden
Copy link
Contributor Author

fixed in PR #1065

@wjhsf wjhsf closed this as completed Mar 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants