Skip to content

Commit

Permalink
Add missing throws tag
Browse files Browse the repository at this point in the history
  • Loading branch information
VincentLanglet authored and ondrejmirtes committed Aug 9, 2023
1 parent 69aaa52 commit e4678fa
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 0 deletions.
2 changes: 2 additions & 0 deletions extension.neon
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ parameters:
- stubs/ORM/Id/AbstractIdGenerator.stub
- stubs/ORM/Mapping/ClassMetadata.stub
- stubs/ORM/Mapping/ClassMetadataInfo.stub
- stubs/ORM/NonUniqueResultException.stub
- stubs/ORM/ORMException.stub
- stubs/ORM/UnexpectedResultException.stub
- stubs/ORM/Query/Expr.stub
- stubs/ORM/Query.stub
- stubs/ORM/Query/Expr/Comparison.stub
Expand Down
3 changes: 3 additions & 0 deletions stubs/ORM/AbstractQuery.stub
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
namespace Doctrine\ORM;

use Doctrine\Common\Collections\ArrayCollection;
use Doctrine\ORM\NonUniqueResultException;

/**
* @template-covariant TKey The type of column used in indexBy
Expand All @@ -22,6 +23,8 @@ abstract class AbstractQuery

/**
* @return bool|float|int|string|null
*
* @throws NonUniqueResultException
*/
public function getSingleScalarResult();

Expand Down
7 changes: 7 additions & 0 deletions stubs/ORM/NonUniqueResultException.stub
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?php

namespace Doctrine\ORM;

class NonUniqueResultException extends UnexpectedResultException
{
}
9 changes: 9 additions & 0 deletions stubs/ORM/UnexpectedResultException.stub
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<?php

namespace Doctrine\ORM;

use Doctrine\ORM\Exception\ORMException;

class UnexpectedResultException extends ORMException
{
}

0 comments on commit e4678fa

Please sign in to comment.