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

CORS headers not set on exception (SLIM bypasses middleware) #14

Open
patricksavalle opened this issue Apr 11, 2016 · 0 comments
Open

Comments

@patricksavalle
Copy link

The problem is that SLIM bypasses the middleware that sets the CORS headers in some cases. A quick patch would be to change
protected function setCorsHeaders($req, $rsp)

Into
public function setCorsHeaders($req, $rsp) {

So this function can be called 'manually' from the (custom) 404, 406 and Errorhandlers.

But maybe it is not a big problem at all. Or maybe there is a better solution.

We use: "palanik/corsslim": "dev-slim3"

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

No branches or pull requests

1 participant