Fix doc comments

This commit is contained in:
Dylan K. Taylor 2024-11-13 18:49:32 +00:00
parent 409066c8f5
commit a6a44bde90
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D
2 changed files with 4 additions and 3 deletions

View File

@ -30,7 +30,7 @@ use function in_array;
class AsyncRegisteredListener{
/**
* @phpstan-param \Closure(AsyncEvent) : Promise<null> $handler
* @phpstan-param \Closure(AsyncEvent) : ?Promise<null> $handler
*/
public function __construct(
private \Closure $handler,

View File

@ -697,8 +697,9 @@ class PluginManager{
/**
* @param string $event Class name that extends Event and AsyncEvent
*
* @phpstan-param class-string<AsyncEvent> $event
* @phpstan-param \Closure(AsyncEvent) : Promise<null> $handler
* @phpstan-template TEvent of AsyncEvent
* @phpstan-param class-string<TEvent> $event
* @phpstan-param \Closure(TEvent) : ?Promise<null> $handler
*
* @throws \ReflectionException
*/