Skip to content

Commit

Permalink
Merge pull request #16 from chernecov/in-array-validator-improvements
Browse files Browse the repository at this point in the history
[Validators] In array validator improvement.
  • Loading branch information
inferont committed Aug 28, 2015
2 parents 0ce6929 + 6369266 commit 7e2d18e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Validator/Constraints/InArrayValidator.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function validate($value, Constraint $constraint)
if (!$constraint instanceof InArray) {
throw new \Exception('This constraint must be instance of EcentriaRestBundle:InArray');
}
if (!in_array($value, $constraint->values)) {
if (!in_array($value, $constraint->values, true)) {
$this->context->addViolation(
sprintf(
"Value '%s' is not supported. Possible values: \"'%s'\"",
Expand Down

0 comments on commit 7e2d18e

Please sign in to comment.