Skip to content

Commit

Permalink
Fix Psalm type resolving
Browse files Browse the repository at this point in the history
  • Loading branch information
samdark committed Feb 16, 2021
1 parent 687525c commit 1c8e2dc
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Provider/ListenerCollection.php
Expand Up @@ -7,6 +7,7 @@
use Closure;
use InvalidArgumentException;
use ReflectionFunction;
use ReflectionNamedType;

/**
* Listener collection stores listeners and is used to configure provider.
Expand Down Expand Up @@ -80,6 +81,7 @@ private function getParameterType(callable $callable): string
if ($reflectedType === null) {
throw new InvalidArgumentException('Listeners must declare an object type they can accept.');
}
/** @var ReflectionNamedType $reflectedType */
return $reflectedType->getName();
}
}

0 comments on commit 1c8e2dc

Please sign in to comment.