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

Throw an explicit error if the header value is not a string #53

Merged
merged 1 commit into from Jun 1, 2018

Conversation

fatso83
Copy link
Contributor

@fatso83 fatso83 commented Jun 1, 2018

According to RFC7230 (last paragraph), http fields have used to be text and new headers should continue to do so, restricting the values to consist of US-ASCII octets.

This test is not so strict, but we avoid a whole range of errors by just checking if the value is a string.

Ref #51 and #48

According to RFC7230, http fields have used to be text and new
headers should continue to do so, restricting the values to consist
of US-ASCII octets.

This test is not so strict, but we avoid a whole range of errors
by just checking if the value is a string.

Ref sinonjs#51, sinonjs#48 and https://tools.ietf.org/html/rfc7230#section-3.2.4
@fatso83 fatso83 merged commit da7324b into sinonjs:master Jun 1, 2018
@fatso83 fatso83 deleted the explicit-error branch June 1, 2018 09:45
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.

None yet

1 participant