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

Send credentials to same-origin #9

Closed
wants to merge 1 commit into from

Conversation

topaxi
Copy link

@topaxi topaxi commented Dec 24, 2016

Authorized API requests started failing using this addon. Allowing fetch to send credentials to same-origin solved this issue. I think it might sense to make this configurable, but I'm not sure how to do this.

By authorized in mean an Authorization HTTP header, but this should also address cases with cookies.

JackCA added a commit to JackCA/ember-service-worker-cache-fallback that referenced this pull request Sep 8, 2017
@JackCA
Copy link

JackCA commented Sep 8, 2017

I had this same issue and just reimplemented this PR against master at https://github.com/JackCA/ember-service-worker-cache-fallback/tree/add-credentials.

Is there any concern around this, @bcardarella?

@eshtadc
Copy link
Contributor

eshtadc commented Dec 14, 2018

I know this is a bit old now, but I agree that it should be a configuration. Taking a look.

@eshtadc
Copy link
Contributor

eshtadc commented Dec 14, 2018

Seems like there should be a more holistic approach here as any plugins dealing with caching do some sort of fetch call. I see in ember-service-worker-index that credentials are set to "include" but the rest do not supply credentials. I'm inclined to want to allow fetch init options (or at least a subset of them) to be set in the main ember-service-worker addon and read by any sw plugin that wants to use them.

@topaxi
Copy link
Author

topaxi commented Aug 6, 2019

I guess since there is an alternative fix proposed, this issue can be closed :)

@topaxi topaxi closed this Aug 6, 2019
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

3 participants