Skip to content

Commit

Permalink
Fix return type at EntityManagerInterface::get(Partial)Reference()
Browse files Browse the repository at this point in the history
  • Loading branch information
simPod committed Aug 16, 2021
1 parent d636d79 commit d7de029
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions lib/Doctrine/ORM/EntityManagerInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
use BadMethodCallException;
use DateTimeInterface;
use Doctrine\Common\EventManager;
use Doctrine\Common\Proxy\Proxy;
use Doctrine\DBAL\Connection;
use Doctrine\ORM\Internal\Hydration\AbstractHydrator;
use Doctrine\ORM\Proxy\ProxyFactory;
Expand Down Expand Up @@ -169,7 +170,7 @@ public function createQueryBuilder();
* @psalm-param class-string<T> $entityName
*
* @return object|null The entity reference.
* @psalm-return ?T
* @psalm-return (T&Proxy)|null
*
* @throws ORMException
*
Expand All @@ -194,8 +195,12 @@ public function getReference($entityName, $id);
*
* @param string $entityName The name of the entity type.
* @param mixed $identifier The entity identifier.
* @psalm-param class-string<T> $entityName
*
* @return object|null The (partial) entity reference
* @psalm-return (T&Proxy)|null
*
* @return object|null The (partial) entity reference.
* @template T
*/
public function getPartialReference($entityName, $identifier);

Expand Down

0 comments on commit d7de029

Please sign in to comment.