-
Notifications
You must be signed in to change notification settings - Fork 11.1k
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
Failed when returned Responsable implementation from a Middleware #24156
Comments
Can you submit a PR? |
According to https://laravel-news.com/laravel-5-5-responsable. The object will be converted to HTTP Response when returned from controller or route closure However, meanwhile it can work like this.
|
@rafaelbeckel Yes. I have already implemented it that way. But, the behavior conflicts with the idea that Meanwhile, I am working on a PR to fix this. |
- This is a fix for issue laravel#24156 which states that. When we return Implementation of Responsable from middleware it fails.
- This is a fix for issue laravel#24156 which states that. When we return Implementation of Responsable from middleware it fails.
- This is a fix for issue laravel#24156 which states that. When we return Implementation of Responsable from middleware it fails.
- This is a fix for issue laravel#24156 which states that. When we return Implementation of Responsable from middleware it fails.
Description:
When you return a Concrete implementation of
Illuminate\Contracts\Support\Responsable
from a middleware it throws error:Steps To Reproduce:
1. Create a Response Class:
2. Create a Middleware:
3. Add in Kernel:
4. Add in Route (web.php):
5. Now, visit that Route:
The text was updated successfully, but these errors were encountered: