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

A request header's default value can now be overwritten. #123

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

A request header's default value can now be overwritten. #123

wants to merge 1 commit into from

Conversation

ghost
Copy link

@ghost ghost commented Dec 22, 2015

The default value of */* for the Accept header can cause undesirable behavior. For example, I am dealing with an API that can serve XML or JSON, but I cannot get it to return JSON due to the default value being first in the list. This change makes it so that if the setRequestHeader is called on a header that is currently set to its default value, it will overwrite the value instead of appending to it.

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.

0 participants