8000 Pass validation groups to All validator. · symfony/symfony@cdd0249 · GitHub
[go: up one dir, main page]

Skip to content

Commit cdd0249

Browse files
committed
Pass validation groups to All validator.
1 parent ead215c commit cdd0249

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Symfony/Component/Validator/Constraints/AllValidator.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,12 @@ public function validate($value, Constraint $constraint)
4444
$validator = $context->getValidator()->inContext($context);
4545

4646
foreach ($value as $key => $element) {
47-
$validator->atPath('['.$key.']')->validate($element, $constraint->constraints);
47+
$validator->atPath('['.$key.']')->validate($element, $constraint->constraints, $constraint->groups);
4848
}
4949
} else {
5050
// 2.4 API
5151
foreach ($value as $key => $element) {
52-
$context->validateValue($element, $constraint->constraints, '['.$key.']');
52+
$context->validateValue($element, $constraint->constraints, '['.$key.']', $constraint->groups);
5353
}
5454
}
5555
}

0 commit comments

Comments
 (0)
0