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

Pass withCredentials on to the XHR #79

Merged
merged 2 commits into from Jun 19, 2017

Conversation

kmayer
Copy link
Contributor

@kmayer kmayer commented Jun 19, 2017

  • See https://www.w3.org/TR/eventsource/#dom-eventsource-withcredentials
  • I noticed during application testing that {withCredentials: true} was
    not including the session cookie, in fact, setting the flag in the polyfill
    had no effect at all. After a little digging, I learned that simply passing
    the option to the http object was all that was needed.
  • I tried writing a test to confirm this, but could not figure out a way to
    do it (the only difference in real life is that the Cookie header is set
    if there's a cookie in the document

kmayer and others added 2 commits June 19, 2017 10:37
- See https://www.w3.org/TR/eventsource/#dom-eventsource-withcredentials
- I noticed during application testing that `{withCredentials: true}` was
  not including the session cookie, in fact, setting the flag in the polyfill
  had no effect at all. After a little digging, I learned that simply passing
  the option to the `http` object was that was needed.
- I tried writing a test to confirm this, but could not figure out a way to
  do it (the only difference in real life is that the `Cookie` header is set
  if there's a cookie in the `document`
@rexxars rexxars merged commit a408997 into EventSource:master Jun 19, 2017
@rexxars
Copy link
Member

rexxars commented Jun 19, 2017

Thanks!

@rexxars
Copy link
Member

rexxars commented Jun 19, 2017

Published as v1.0.4

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

2 participants