-
-
Notifications
You must be signed in to change notification settings - Fork 73
Child Processes - feedback #54
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
Child Processes - feedback #54
Conversation
use Illuminate\Support\Facades\Event; | ||
use Native\Laravel\Events\ChildProcess\MessageReceived; | ||
|
||
/** | ||
* Bootstrap any application services. | ||
*/ | ||
public function boot(): void | ||
{ | ||
Event::listen(MessageReceived::class, function(MessageReceived $event) { | ||
if ($event->alias === 'tail') { | ||
// | ||
} | ||
}); | ||
} | ||
|
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 removed the protected $listen
example in favour for Event::listen
in the app service provider.
Since Laravel 11 the property approach was removed from the docs. Having two examples that do the same thing right next to each other seemed confusing to me
Ready for review @simonhamp |
No description provided.