You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I updated Ember to 3.13 (including ember-data, using ember-cli-update) and disabled the jQuery integration. In the Adapter I was using the authorize function to set the token, like this:
When the user is logged in the headers are set correctly. But if I logout in another tab and refresh the old tab into which I was logged in, the request is sent without headers. Even the origin header is omitted and therefore the request is blocked by the browser (CORS) since we have Access-Control set up.
I have also tried to overwrite the ajaxOptions to set the headers and set the fetch credentials property to include to allow CORS request, but it didn't work either.
The text was updated successfully, but these errors were encountered:
I'm running into this exact issue too. I'm not even sure it's the fault of ember-simple-auth... Effectively we can't get a new app deployed since we're not able to set the Access-Control-Allow-Origin header added to the unauthenticated requests.
I updated Ember to 3.13 (including ember-data, using
ember-cli-update
) and disabled the jQuery integration. In the Adapter I was using theauthorize
function to set the token, like this:Since this function is no longer called when using
ember-fetch
, I replaced it with theheaders
computed property, as mentioned in the DOC.When the user is logged in the headers are set correctly. But if I logout in another tab and refresh the old tab into which I was logged in, the request is sent without headers. Even the
origin
header is omitted and therefore the request is blocked by the browser (CORS) since we haveAccess-Control
set up.I have also tried to overwrite the
ajaxOptions
to set the headers and set the fetchcredentials
property toinclude
to allow CORS request, but it didn't work either.The text was updated successfully, but these errors were encountered: