Skip to content

Commit

Permalink
Merge branch '4.4' into 5.0
Browse files Browse the repository at this point in the history
* 4.4:
  Tweak the code to avoid fabbot false positives
  • Loading branch information
fabpot committed Apr 12, 2020
2 parents d01fd93 + e24eb5f commit b313fe5
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Constraints/AbstractComparisonValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ public function validate($value, Constraint $constraint)
try {
$comparedValue = $this->getPropertyAccessor()->getValue($object, $path);
} catch (NoSuchPropertyException $e) {
throw new ConstraintDefinitionException(sprintf('Invalid property path "%s" provided to "%s" constraint: %s.', $path, \get_class($constraint), $e->getMessage()), 0, $e);
throw new ConstraintDefinitionException(sprintf('Invalid property path "%s" provided to "%s" constraint: '.$e->getMessage(), $path, \get_class($constraint)), 0, $e);
}
} else {
$comparedValue = $constraint->value;
Expand Down
2 changes: 1 addition & 1 deletion Constraints/CallbackValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function validate($object, Constraint $constraint)
if (isset($method[0]) && \is_object($method[0])) {
$method[0] = \get_class($method[0]);
}
throw new ConstraintDefinitionException(sprintf('%s targeted by Callback constraint is not a valid callable.', json_encode($method)));
throw new ConstraintDefinitionException(json_encode($method).' targeted by Callback constraint is not a valid callable.');
}

$method($object, $this->context, $constraint->payload);
Expand Down

0 comments on commit b313fe5

Please sign in to comment.