[EventDispatcher] Removed "callable" type hint from WrappedListener constructor

This commit is contained in:
Wojciech Skorodecki 2019-05-17 15:28:19 +02:00
parent c5772ae9bc
commit 20c587fc23

View File

@ -38,7 +38,7 @@ class WrappedListener
private $priority; private $priority;
private static $hasClassStub; private static $hasClassStub;
public function __construct(callable $listener, ?string $name, Stopwatch $stopwatch, EventDispatcherInterface $dispatcher = null) public function __construct($listener, ?string $name, Stopwatch $stopwatch, EventDispatcherInterface $dispatcher = null)
{ {
$this->listener = $listener; $this->listener = $listener;
$this->optimizedListener = $listener instanceof \Closure ? $listener : \Closure::fromCallable($listener); $this->optimizedListener = $listener instanceof \Closure ? $listener : \Closure::fromCallable($listener);