From 8789d9dc70df9fe83c9c25ff715c62903bf1817d Mon Sep 17 00:00:00 2001 From: Maxime Helias Date: Tue, 3 Mar 2020 15:17:37 +0100 Subject: [PATCH] make:subscriber: fix list active event --- src/EventRegistry.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/EventRegistry.php b/src/EventRegistry.php index a73b9a91b..7c4a5f64c 100644 --- a/src/EventRegistry.php +++ b/src/EventRegistry.php @@ -107,6 +107,10 @@ public function getAllActiveEvents(): array if (isset(self::$newEventsMap[$listenerKey])) { unset($listeners[$listenerKey]); } + + if (!isset(self::$eventsMap[$listenerKey])) { + self::$eventsMap[$listenerKey] = $this->getEventClassName($listenerKey); + } } $activeEvents = array_unique(array_merge($activeEvents, array_keys($listeners)));