-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
minor #19765 [Validator] feat: add warning for number constraints wit…
…h PHP 7.x (alexislefebvre) This PR was merged into the 5.4 branch. Discussion ---------- [Validator] feat: add warning for number constraints with PHP 7.x Fixes symfony/symfony#45710 See: - symfony/symfony#45710 Symfony 6.x requires PHP 8.x and it fixes this inconsistency, see symfony/symfony#45710 (comment) So this patch should be removed when merging `5.4` in `6.0` (or `6.4`). Commits ------- 7341079 feat: add warning for number constraints with PHP 7.x
- Loading branch information
Showing
9 changed files
with
22 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
.. caution:: | ||
|
||
When using PHP 7.x, if the value is a string (e.g. ``1234asd``), the validator | ||
will not trigger an error. In this case, you must also use the | ||
:doc:`Type constraint </reference/constraints/Type>` with | ||
``numeric``, ``integer`, etc. to reject strings. |