From 93fa799fa43923302481a08d588fdb80689f5d69 Mon Sep 17 00:00:00 2001 From: rgrassian <46503877+rgrassian@users.noreply.github.com> Date: Thu, 3 Mar 2022 18:56:04 +0100 Subject: [PATCH] fix query stub (#114) --- stubs/EntityRepository.phpstub | 8 -------- stubs/Query.phpstub | 2 +- stubs/QueryBuilder.phpstub | 3 +-- 3 files changed, 2 insertions(+), 11 deletions(-) diff --git a/stubs/EntityRepository.phpstub b/stubs/EntityRepository.phpstub index c132850..e0dc548 100644 --- a/stubs/EntityRepository.phpstub +++ b/stubs/EntityRepository.phpstub @@ -73,12 +73,4 @@ class EntityRepository implements ObjectRepository, Selectable public function matching(Criteria $criteria) { } - - /** - * @return QueryBuilder - */ - public function createQueryBuilder($alias, $indexBy = null): QueryBuilder - { - - } } diff --git a/stubs/Query.phpstub b/stubs/Query.phpstub index ae56fd2..c8b2757 100644 --- a/stubs/Query.phpstub +++ b/stubs/Query.phpstub @@ -8,7 +8,7 @@ namespace Doctrine\ORM; class Query extends AbstractQuery { /** - * @param int $hydrationMode + * @param int|string $hydrationMode * * @psalm-return ( * $hydrationMode is self::HYDRATE_OBJECT diff --git a/stubs/QueryBuilder.phpstub b/stubs/QueryBuilder.phpstub index c7bfae2..b704b2a 100644 --- a/stubs/QueryBuilder.phpstub +++ b/stubs/QueryBuilder.phpstub @@ -7,7 +7,6 @@ use Doctrine\ORM\Query\Expr; /** * @psalm-type _WhereExpr=Expr\Base|Expr\Comparison|Expr\Func|string * @psalm-type _SelectExpr=Expr\Func|string - * @template T */ class QueryBuilder { @@ -93,7 +92,7 @@ class QueryBuilder /** - * @return Query + * @return Query */ public function getQuery(): Query {