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

json2xml plugin incorrectly changes request 'content-length' header #184

Open
mecclesgoogle opened this issue May 18, 2020 · 0 comments
Open

Comments

@mecclesgoogle
Copy link

Lines #137 and #141

The request object has all header names in lower case, but the code uses Capital case.

req.headers['Content-Type'] = ...

This will result in the same header being appended. I.e. it ends up with 'Content-Type' and 'content-type'.
The fix should be to assign the header using the lower-case name.

n.b. setHeader(.., ..) method is not available on the IncomingRequest type.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant