I've got an Angular5 app and use the Pi Web API client library service to make requests to the PI Web API.
But I'm having an issue with the requests failing with the error "Response for preflight is invalid (redirect)", about half the time.
Sometimes the requests work fine, and other times they don't. With no code or config changes.
And it affects both GET and POST requests.
I think I'm pretty well across CORS and have tried numerous configurations without any luck.
I have even set the CorsMethods/Headers/Origins to * to try and get it working properly.
The problem is, the preflight actually returns an OK 200 response, but the actual request isn't triggered because of the error.
I've tried using Basic and Kerberos authentication methods.
And this only affects Chrome, while IE works fine.
Any help would be greatly appreciated, thanks