-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Support case insensitive query parameters #2644
Comments
Yes of course! Would you like to send a PR? Note that you can work around this pretty easily by overwriting https://www.fastify.io/docs/latest/Server/#querystringparser, which would by recommended fix, e.g. call |
I won't be able to access my computer next week, so if someone wants to fix it before they are more than welcome. Otherwise I'll have a look in a week time |
I'm happy to take a look into this today :-) |
Great, thanks! |
Include a lowercase formatting when the case sensitive option is disabled fastify#2644
By setting the caseSensitive option to false, it also gets applied to query strings, not only routes. See fastify#2644.
Hey, guys, I've just opened a PR to address this issue but there are some things to consider about this, which I commented in the PR: #2649 |
Looks like someone else beat me to it 😑 |
I'm sorry, @julesnuggy :( |
Looking at closed PRs it seems like this should change to a docs PR to recommend using qs for case insensitivity. |
Correct. Would you like to create that PR? |
If this issue still persists can I work on this? |
go for it! |
I checked the contributing guidelines, I have a little doubt. Do I need to fork this repo or I will get contributing access to this repo? |
Please follow the traditional GitHub workflow of:
|
@Nazeeh21 what is unclear about the error? The coverage requirements are not met. Also, the desired "fix" for this issue is a documentation change, not a code change: |
There is a misunderstanding on my side. Sorry for that. I'll soon submit a PR with the required fix in the documentation. |
🚀 Feature Proposal
Could it be possible to support an optional case insentive option for query parameters? Adding the option
caseSensitive: false
does not seems to impact query parametersMotivation
For backward compatibilitites you sometime need to support multiple casing
Example
With that code
Both tests below should pass
The text was updated successfully, but these errors were encountered: