diff --git a/src/infrastructure/events/PhabricatorEventEngine.php b/src/infrastructure/events/PhabricatorEventEngine.php index 2f14a2d1e7..8d49752d61 100644 --- a/src/infrastructure/events/PhabricatorEventEngine.php +++ b/src/infrastructure/events/PhabricatorEventEngine.php @@ -1,28 +1,35 @@ register(); + try { + id(new $listener())->register(); + } catch (Exception $ex) { + // If the listener does not exist, or throws when registering, just + // log it and continue. In particular, this is important to let you + // run `bin/config` in order to remove an invalid listener. + phlog($ex); + } } // Register the DarkConosole event logger. id(new DarkConsoleEventPluginAPI())->register(); id(new ManiphestEdgeEventListener())->register(); $applications = PhabricatorApplication::getAllInstalledApplications(); foreach ($applications as $application) { $listeners = $application->getEventListeners(); foreach ($listeners as $listener) { $listener->register(); } } } }