Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing throws tag #467

Merged
merged 1 commit into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
{
}