From 7ef3c95fa343d7d159958c843436183a1cbf252f Mon Sep 17 00:00:00 2001 From: Christoph Wurst Date: Wed, 28 Oct 2020 08:54:24 +0100 Subject: [PATCH] Type the event dispatcher listener callables with Psalm Signed-off-by: Christoph Wurst --- lib/public/EventDispatcher/IEventDispatcher.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/public/EventDispatcher/IEventDispatcher.php b/lib/public/EventDispatcher/IEventDispatcher.php index 471447e4b9..9f9bd2ebd1 100644 --- a/lib/public/EventDispatcher/IEventDispatcher.php +++ b/lib/public/EventDispatcher/IEventDispatcher.php @@ -39,6 +39,7 @@ interface IEventDispatcher { * @param string $eventName preferably the fully-qualified class name of the Event sub class * @psalm-param string|class-string $eventName preferably the fully-qualified class name of the Event sub class * @param callable $listener the object that is invoked when a matching event is dispatched + * @psalm-param callable(T):void $listener * @param int $priority * * @since 17.0.0 @@ -50,6 +51,7 @@ interface IEventDispatcher { * @param string $eventName preferably the fully-qualified class name of the Event sub class * @psalm-param string|class-string $eventName preferably the fully-qualified class name of the Event sub class * @param callable $listener the object that is invoked when a matching event is dispatched + * @psalm-param callable(T):void $listener * * @since 19.0.0 */