Przeglądaj źródła

Don't throw exception in the doDispatch method.

Max Gfeller 11 lat temu
rodzic
commit
a12ed492ef
1 zmienionych plików z 0 dodań i 4 usunięć
  1. 0 4
      src/Composer/EventDispatcher/EventDispatcher.php

+ 0 - 4
src/Composer/EventDispatcher/EventDispatcher.php

@@ -118,10 +118,6 @@ class EventDispatcher
     {
         $listeners = $this->getListeners($event);
 
-        if(sizeof($listeners) === 0) {
-            throw new \InvalidArgumentException(sprintf('Script "%s" does not exist', $event->getName()));
-        }
-
         foreach ($listeners as $callable) {
             if (!is_string($callable) && is_callable($callable)) {
                 call_user_func($callable, $event);