diff options
author | Morris Jobke <hey@morrisjobke.de> | 2020-10-30 11:54:48 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-30 11:54:48 +0300 |
commit | 1654826e83d5e3150a8b609f6476af631657204e (patch) | |
tree | 781700d621b345cdc48a5e20a9518e3efd9a5bb7 /lib | |
parent | 54888587cddde8c4d9a4edebcaad61fc6537f759 (diff) | |
parent | 22f04a7cc3d6911652452773c9432af6d53f90f7 (diff) |
Merge pull request #23742 from nextcloud/enhancement/eventdispatcher-typed-listener-callable
Type the event dispatcher listener callables with Psalm
Diffstat (limited to 'lib')
-rw-r--r-- | lib/public/EventDispatcher/IEventDispatcher.php | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/public/EventDispatcher/IEventDispatcher.php b/lib/public/EventDispatcher/IEventDispatcher.php index 095178f16e1..6f3adf159c0 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<T> $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<T> $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 */ |