You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
ok just as i was writting i though of how it can be fixed, if ther are leading backslashes we can just remove them in the event formatter, pr coming soon.
I get why its done, make it easier etc.
The test done on the event wont work from what i can see.
Events come through without the leading backslash, regardless of if there are from \App\Events or \Package\Events
php get_class or Class::class never give you the leading backslash.
for example if you fire the event:
event(new Package\Event)
this will never be matched, because:
channel.listen('Package\\Event');
will listen forApp\\Events\\Package\\Event
and
channel.listen('\\Package\\Event');
will listen for\\Package\\Event
but the actual event fired will be
Package\\Event
i dont have a solution, just thinking of future use cases.
The text was updated successfully, but these errors were encountered: