-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
🩹 Allow parsing of square bracket query param #1818
🩹 Allow parsing of square bracket query param #1818
Conversation
Thanks for opening this pull request! 🎉 Please check out our contributing guidelines. If you need help or want to chat with us, join us on Discord https://gofiber.io/discord |
ced5220
to
effe03e
Compare
Please add a benchmark |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add before/after benchmark results of queryparser?
Also, can you add new benchmark for this feature?
effe03e
to
5a7744d
Compare
I did the benchmarking: BEFORE:
AFTER:
Benchmarking for the method
|
I also tried with
Benchmarking:
Benchmark the only method:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Check linter and gosec error.
thx pls check the comment from efectn
|
5a7744d
to
422315a
Compare
I handled the error handling, don't know if it is valid to |
Check my last comment |
422315a
to
ac6ed60
Compare
I think we can add add example for this usage to docs. It would be helpful also. What about @ninadingole |
will update the doc |
Congrats on merging your first pull request! 🎉 We here at Fiber are proud of you! If you need help or want to chat with us, join us on Discord https://gofiber.io/discord |
closes #1802
Explain the details for making this change. What existing problem does the pull request solve?
The PR solves the issue of parsing query params that contains array key in
[]
format. Following type of keys are parsed and the tests are added:data[]=john&data[]=doe
data[0][name]=john&data[0][age]=10&data[1][name]=doe&data[1][age]=12
// This will be parsed to a structdata.0.name=john&data.0.age=10&data.1.name=doe&data.1.age=12