-
Notifications
You must be signed in to change notification settings - Fork 407
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
Improvements to Dispatcher class #567
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you did some improvements which if they work out will help the code be cleaner which I appreciate! Your code editor is messing up a few things that need to be corrected though. And the only other thing is that I don't want to introduce dependencies into Flight, that's part of the selling point.
@fadrian06 Why'd you close the PR? It's a good PR just needs a few tweaks |
59bb3f3
to
8f3f6b5
Compare
Tired of declaring after filters with the first parameter without doing anything?
DELETE IT :D, nothing will be broken.
Dispatcher now supports after filters with the only useful parameter.
Now...
To even make it even cleaner, you could change the filter to a PHP 7.4 arrow function.
Just make sure that what you do in the arrow function doesn't return
false
, unless you want to make other after filters for the same mapped method not run.