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

[spring-server] fix: handle graphql request with charset coding #425

Merged
merged 1 commit into from Oct 11, 2019

Conversation

dariuszkuc
Copy link
Collaborator

📝 Description

In our default GraphQL route we were explicitly checking if Content-Type header is just application/json. If request was also specifying charset, e.g. application/json;charset=UTF-8 our logic would fail to match it and result in HTTP 400 (Bad Request) response.

@dariuszkuc dariuszkuc added type: bug Something isn't working changes: patch Changes require a patch version labels Oct 11, 2019
…coding

In our default GraphQL route we were explicitly checking if `Content-Type` header is just `application/json`. If request was also specifying charset, e.g. `application/json;charset=UTF-8` our logic would fail to match it and result in HTTP 400 (Bad Request) response.
@codecov-io
Copy link

codecov-io commented Oct 11, 2019

Codecov Report

Merging #425 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff             @@
##             master    #425      +/-   ##
===========================================
+ Coverage      97.8%   97.8%   +<.01%     
  Complexity      325     325              
===========================================
  Files           105     105              
  Lines          1228    1230       +2     
  Branches        202     202              
===========================================
+ Hits           1201    1203       +2     
  Misses            7       7              
  Partials         20      20
Impacted Files Coverage Δ Complexity Δ
...expediagroup/graphql/spring/RoutesConfiguration.kt 100% <100%> (ø) 8 <0> (ø) ⬇️

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 9816f5c...369c674. Read the comment docs.

@dariuszkuc dariuszkuc merged commit 3c3824a into ExpediaGroup:master Oct 11, 2019
@dariuszkuc dariuszkuc deleted the route_fix branch October 11, 2019 19:14
dariuszkuc added a commit to dariuszkuc/graphql-kotlin that referenced this pull request Aug 5, 2022
…coding (ExpediaGroup#425)

In our default GraphQL route we were explicitly checking if `Content-Type` header is just `application/json`. If request was also specifying charset, e.g. `application/json;charset=UTF-8` our logic would fail to match it and result in HTTP 400 (Bad Request) response.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changes: patch Changes require a patch version type: bug Something isn't working
Development

Successfully merging this pull request may close these issues.

None yet

3 participants