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

fix: resolve redirect paths containing non-ascii characters #439

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

me4502
Copy link

@me4502 me4502 commented Apr 20, 2023

When using non-ascii characters in a URL, the redirect path fails upon upload. This encodes the URI to use encoded path symbols. For non-ascii paths this will make no change

When using non-ascii characters in a URL, the redirect path fails upon upload. This encodes the URI to use encoded path symbols
@YoshiWalsh
Copy link
Collaborator

Thanks for contributing!

I haven't had a chance to test this yet, but would it be better to call encodeURIComponent on redirectPath instead? Is it possible that redirectPath might contain characters such as "#" or "?", and if it does should these also be escaped?

How are your redirects being generated that they contain non-ASCII characters, is toPath always unencoded? Or are there situations where this change might result in double encoding?

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

Successfully merging this pull request may close these issues.

2 participants