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

[8.x] Fixes middleware() not accepting Stringable #39449

Merged
merged 4 commits into from
Nov 2, 2021
Merged

[8.x] Fixes middleware() not accepting Stringable #39449

merged 4 commits into from
Nov 2, 2021

Conversation

DarkGhostHunter
Copy link
Contributor

What?

Fixes declaring routes as Route::get()->middleware() with Stringable objects. As seen on TV:

I may need to revert this already @DarkGhostHunter

This simple test doesn't even work locally:

image image

Originally posted by @taylorotwell in #39439 (comment)

This also removes son unnecessary checks for middleware declaration, as is expected to be an array, or a string (which gets converted to a one-member array anyway).

@DarkGhostHunter
Copy link
Contributor Author

DarkGhostHunter commented Nov 2, 2021

Can someone explain why test fails because of yes?

@driesvints
Copy link
Member

@DarkGhostHunter restarted them for ya

@DarkGhostHunter
Copy link
Contributor Author

Ty. Please don't crash now.

@taylorotwell taylorotwell merged commit 1b1decb into laravel:8.x Nov 2, 2021
@taylorotwell
Copy link
Member

Thanks

@DarkGhostHunter
Copy link
Contributor Author

👌

@DarkGhostHunter DarkGhostHunter deleted the fix/middleware-stringable branch November 2, 2021 18:23
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

Successfully merging this pull request may close these issues.

3 participants