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(core, middleware-body): incorrectly parsed querystrings #104

Merged
merged 1 commit into from
Feb 17, 2019

Conversation

JozefFlakus
Copy link
Member

@JozefFlakus JozefFlakus commented Feb 16, 2019

PR Type

What kind of change does this PR introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

  • @marblejs/core - the query parser cannot parse complex URL encoded strings, like:
foo[bar1][baz]=test1'
foo[bar2][baz]=test2'
  • @marblejs/middlware-body - URL parser incorectly decodes complex application/x-www-form-urlencoded strings like:
foo[bar1][baz]=test1'
foo[bar2][baz]=test2'

or

foo=some=value&which&is=complex

What is the new behavior?

  • @marblejs/core - integration with qs library (a querystring parser with nesting support)
  • @marblejs/middlware-body - ☝️

Does this PR introduce a breaking change?

[ ] Yes
[x] No

@JozefFlakus JozefFlakus added bug Something isn't working scope: middleware Middleware related features or enhancements next Feature or enhancement that will be added in 'next' major version scope: core Relates to @marblejs/core package labels Feb 16, 2019
@JozefFlakus JozefFlakus added this to the 2.0.0-rc.2 milestone Feb 16, 2019
@JozefFlakus JozefFlakus self-assigned this Feb 16, 2019
@codecov
Copy link

codecov bot commented Feb 16, 2019

Codecov Report

Merging #104 into next will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@         Coverage Diff         @@
##           next   #104   +/-   ##
===================================
  Coverage   100%   100%           
===================================
  Files        87     87           
  Lines      1027   1008   -19     
  Branches     81     80    -1     
===================================
- Hits       1027   1008   -19
Impacted Files Coverage Δ
...ges/middleware-body/src/parsers/url.body.parser.ts 100% <100%> (ø) ⬆️
packages/core/src/router/router.query.factory.ts 100% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6c9dafb...f087008. Read the comment docs.

@JozefFlakus JozefFlakus merged commit 46662fd into next Feb 17, 2019
@JozefFlakus JozefFlakus deleted the fix/next/url-encoded branch February 17, 2019 19:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working next Feature or enhancement that will be added in 'next' major version scope: core Relates to @marblejs/core package scope: middleware Middleware related features or enhancements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant