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

Redirects return blank page with HTTP 200 status #11

Closed
zimozy opened this issue Feb 23, 2018 · 1 comment
Closed

Redirects return blank page with HTTP 200 status #11

zimozy opened this issue Feb 23, 2018 · 1 comment

Comments

@zimozy
Copy link

zimozy commented Feb 23, 2018

I couldn't perform redirects:
return $response->withRedirect('/page');
I'd get a blank page with an HTTP 200 status code.

I was able to fix this on my machine by changing
$next($request,$response);
to
$response = $next($request,$response);

(Since the Response is immutable as per the user guide.)

@jissereitsma
Copy link
Contributor

Thanks @zimozy for finding this. I bumped into the same issue. @christianklisch, is this still something you want to maintain? Middleware under Slim 3 requires the solution that @zimozy suggested.

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

3 participants