Skip to content

Commit cd2228e

Browse files
committed
minor symfony#61795 [Validator] Expression constraint docblock incorrectly states default value for negate (nesl247)
This PR was squashed before being merged into the 7.3 branch. Discussion ---------- [Validator] Expression constraint docblock incorrectly states default value for negate | Q | A | ------------- | --- | Branch? | 7.3 | Bug fix? | yes | New feature? | no | Deprecations? | no | Issues | | License | MIT The docblock incorrectly stated that the default is to false. On line 41, you can see that the default is true. Changing the default to match the docblock would cause a BC break, so fixing the documentation instead. Commits ------- 87b0ff2 [Validator] Expression constraint docblock incorrectly states default value for negate
2 parents f324858 + 87b0ff2 commit cd2228e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ class Expression extends Constraint
4444
* @param array<string,mixed>|null $values The values of the custom variables used in the expression (defaults to an empty array)
4545
* @param string[]|null $groups
4646
* @param array<string,mixed>|null $options
47-
* @param bool|null $negate Whether to fail if the expression evaluates to true (defaults to false)
47+
* @param bool|null $negate When set to true, if the expression returns true, the validation will pass (defaults to true)
4848
*/
4949
#[HasNamedArguments]
5050
public function __construct(

0 commit comments

Comments
 (0)