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

Properly decode URL parameters when passed as path segments or query params #114

Merged
merged 2 commits into from
Jan 5, 2024

Conversation

lihaoyi
Copy link
Member

@lihaoyi lihaoyi commented Jan 5, 2024

Fixes #105

getRequestPath seems to parse things wrongly with 1+%2B+1+%3D+2 becoming 1+++1+=+2, losing the distinction between spaces and plus +. Swapped in getRequestURI which gives us the raw string and handled the parsing myself to work around that.

Updated the variableRoutes and queryParams unit tests to make sure they properly provide decoded values to the application code

@lihaoyi lihaoyi merged commit 9df52fc into master Jan 5, 2024
4 checks passed
@lolgab lolgab deleted the url-encoded-params branch January 14, 2024 11:19
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.

Routes containing url-encoded parameters do not work as expected.
1 participant