Skip to content

Conversation

@Mujahid087
Copy link

Summary:
This pull request fixes an issue in bodyDecoder-middleware.js where the server incorrectly handled Content-Type headers containing additional parameters, such as charset=utf-8. The previous implementation used strict string comparisons, which caused issues when headers like application/json; charset=utf-8 or application/x-www-form-urlencoded; charset=utf-8 were received.

Changes:
Replaced strict equality checks with startsWith() to handle Content-Type headers that include additional properties.
Now the server can process requests with headers like application/json; charset=utf-8 and application/x-www-form-urlencoded; charset=utf-8.

@Mujahid087 Mujahid087 closed this by deleting the head repository Oct 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant