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

change test for json|xml to use regex, allow spaces in header value #74

Closed
wants to merge 1 commit into from

Conversation

gmdayley
Copy link

This changes the test for content-type(s) to use a regex. This allow for spaces in content-type header to be correctly detected for json or xml types:

application/json;charset=utf-8
application/json; charset=utf-8
-------------------^-----------------

@aacerox
Copy link
Owner

aacerox commented Apr 20, 2015

Hi @gmdayley
You can set a custom content-type for json or xml using the "mimetypes" initialization parameter. Please refer to documentation (https://github.com/aacerox/node-rest-client#options-parameters) and issues #17 and #12

Thanks.

@aacerox aacerox closed this Apr 20, 2015
@theGrue theGrue mentioned this pull request Jan 12, 2016
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

Successfully merging this pull request may close these issues.

2 participants