Skip to content

Commit

Permalink
Merge 7f99cc0 into 1805077
Browse files Browse the repository at this point in the history
  • Loading branch information
moufmouf committed Mar 6, 2020
2 parents 1805077 + 7f99cc0 commit 9646304
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"require-dev": {
"phpunit/phpunit": "^8.4.1",
"mouf/picotainer": "^1.1",
"phpstan/phpstan": "^0.11.16",
"phpstan/phpstan": "^0.12.14",
"php-coveralls/php-coveralls": "^2.1.0",
"symfony/translation": "^4",
"doctrine/coding-standard": "^7.0"
Expand Down
4 changes: 4 additions & 0 deletions src/ValidationFailedException.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ class ValidationFailedException extends InvalidArgumentException implements Grap
/** @var ConstraintViolationException[] */
private $exceptions = [];

/**
* @param ConstraintViolationListInterface<ConstraintViolationInterface> $constraintViolationList
*/
public function __construct(ConstraintViolationListInterface $constraintViolationList)
{
parent::__construct('Validation failed:', 400);
Expand Down Expand Up @@ -48,6 +51,7 @@ public function hasExceptions(): bool
* If only one exception is passed, it is thrown.
* If many exceptions are passed, they are bundled in the GraphQLAggregateException
*
* @param ConstraintViolationListInterface<ConstraintViolationInterface> $constraintViolationList
* @throws ValidationFailedException
*/
public static function throwException(ConstraintViolationListInterface $constraintViolationList): void
Expand Down

0 comments on commit 9646304

Please sign in to comment.