diff --git a/src/ListenerProvider.php b/src/ListenerProvider.php index efd057c..b75aa65 100644 --- a/src/ListenerProvider.php +++ b/src/ListenerProvider.php @@ -11,7 +11,6 @@ use Phly\KeepAChangelog\Common\EventInterface; use Psr\EventDispatcher\ListenerProviderInterface; -use function get_class; use function is_object; class ListenerProvider implements ListenerProviderInterface @@ -164,7 +163,7 @@ class ListenerProvider implements ListenerProviderInterface public function getListenersForEvent(object $event): iterable { - $type = get_class($event); + $type = $event::class; if (! isset($this->listeners[$type])) { return []; }