CORS error is missing in the preflight call
hello! we re getting a CORS error is missing, even though we added the nedded headers. after investigating we saw that in the preflight call the headers look like this:
OPTIONS /url... Access-Control-Request-Method: GET Access-Control-Request-Headers: access-control-allow-origin,authentication-source,authority,authorization,cache-control
if you see the Access-Control-Request-Headers become comma separated and the values are missing.. and the same happens in the normal call that follows.. Any idea if this has happened before or what we can do?
Thanks a lot!
@karakostasi Can you share your code snippet on how you use SSE and configure the headers you're trying to send?
The sse.js library doesn't do any transformation on the headers, it just passes them on to the underlying XMLHttpRequest:
for (let header in this.headers) {
this.xhr.setRequestHeader(header, this.headers[header]);
}