Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 0b7c2ba

Browse filesBrowse files
Fixed coding standards
1 parent 8454893 commit 0b7c2ba
Copy full SHA for 0b7c2ba

File tree

2 files changed

+4
-4
lines changed
Filter options

2 files changed

+4
-4
lines changed

‎src/Symfony/Component/Validator/Constraints/AtLeastOne.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Constraints/AtLeastOne.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class AtLeastOne extends Composite
2424
protected static $errorNames = [
2525
self::AT_LEAST_ONE_ERROR => 'AT_LEAST_ONE_ERROR',
2626
];
27-
27+
2828
public $constraints = [];
2929
public $message = 'This value should satisfy at least one of the following constraints:';
3030
public $messageCollection = 'Each element of this collection should satisfy its own set of constraints.';

‎src/Symfony/Component/Validator/Constraints/AtLeastOneValidator.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Validator/Constraints/AtLeastOneValidator.php
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,20 +36,20 @@ public function validate($value, Constraint $constraint)
3636
foreach ($constraint->constraints as $key => $item) {
3737
$violations = $validator->validate($value, $item);
3838

39-
if (0 === count($violations)) {
39+
if (0 === \count($violations)) {
4040
return;
4141
}
4242

4343
if ($constraint->includeInternalMessages) {
44-
$message = ' ['.($key+1).'] ';
44+
$message = ' ['.($key + 1).'] ';
4545

4646
if ($item instanceof All || $item instanceof Collection) {
4747
$message .= $constraint->messageCollection;
4848
} else {
4949
$message .= $violations->get(0)->getMessage();
5050
}
5151

52-
$messages[] = $message;
52+
$messages[] = $message;
5353
}
5454
}
5555

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.