You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Constraints/Email.php
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -51,15 +51,15 @@ class Email extends Constraint
51
51
public$checkHost = false;
52
52
53
53
/**
54
-
* @deprecated since Symfony 4.1, to be removed in 5.0. Set mode to "strict" instead.
54
+
* @deprecated since Symfony 4.1. Set mode to "strict" instead.
55
55
*/
56
56
public$strict;
57
57
public$mode;
58
58
59
59
publicfunction__construct($options = null)
60
60
{
61
61
if (is_array($options) && array_key_exists('strict', $options)) {
62
-
@trigger_error(sprintf('The "strict" property is deprecated since Symfony 4.1 and will be removed in 5.0. Use "mode"=>"%s" instead.', self::VALIDATION_MODE_STRICT), E_USER_DEPRECATED);
62
+
@trigger_error(sprintf('The "strict" property is deprecated since Symfony 4.1. Use "mode"=>"%s" instead.', self::VALIDATION_MODE_STRICT), E_USER_DEPRECATED);
63
63
}
64
64
65
65
if (is_array($options) && array_key_exists('mode', $options) && !in_array($options['mode'], self::$validationModes, true)) {
@trigger_error(sprintf('Calling `new %s(%s)` is deprecated since Symfony 4.1 and will be removed in 5.0, use `new %s("%s")` instead.', self::class, $defaultMode ? 'true' : 'false', self::class, $defaultMode ? Email::VALIDATION_MODE_STRICT : Email::VALIDATION_MODE_LOOSE), E_USER_DEPRECATED);
52
+
@trigger_error(sprintf('Calling `new %s(%s)` is deprecated since Symfony 4.1, use `new %s("%s")` instead.', self::class, $defaultMode ? 'true' : 'false', self::class, $defaultMode ? Email::VALIDATION_MODE_STRICT : Email::VALIDATION_MODE_LOOSE), E_USER_DEPRECATED);
@@ -81,7 +81,7 @@ public function validate($value, Constraint $constraint)
81
81
$value = (string) $value;
82
82
83
83
if (null !== $constraint->strict) {
84
-
@trigger_error(sprintf('The %s::$strict property is deprecated since Symfony 4.1 and will be removed in 5.0. Use %s::mode="%s" instead.', Email::class, Email::class, Email::VALIDATION_MODE_STRICT), E_USER_DEPRECATED);
84
+
@trigger_error(sprintf('The %s::$strict property is deprecated since Symfony 4.1. Use %s::mode="%s" instead.', Email::class, Email::class, Email::VALIDATION_MODE_STRICT), E_USER_DEPRECATED);
Copy file name to clipboardExpand all lines: Constraints/Url.php
+17-17Lines changed: 17 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -22,67 +22,67 @@
22
22
class Url extends Constraint
23
23
{
24
24
/**
25
-
* @deprecated since Symfony 4.1, to be removed in 5.0
25
+
* @deprecated since Symfony 4.1
26
26
*/
27
27
constCHECK_DNS_TYPE_ANY = 'ANY';
28
28
29
29
/**
30
-
* @deprecated since Symfony 4.1, to be removed in 5.0
30
+
* @deprecated since Symfony 4.1
31
31
*/
32
32
constCHECK_DNS_TYPE_NONE = false;
33
33
34
34
/**
35
-
* @deprecated since Symfony 4.1, to be removed in 5.0
35
+
* @deprecated since Symfony 4.1
36
36
*/
37
37
constCHECK_DNS_TYPE_A = 'A';
38
38
39
39
/**
40
-
* @deprecated since Symfony 4.1, to be removed in 5.0
40
+
* @deprecated since Symfony 4.1
41
41
*/
42
42
constCHECK_DNS_TYPE_A6 = 'A6';
43
43
44
44
/**
45
-
* @deprecated since Symfony 4.1, to be removed in 5.0
45
+
* @deprecated since Symfony 4.1
46
46
*/
47
47
constCHECK_DNS_TYPE_AAAA = 'AAAA';
48
48
49
49
/**
50
-
* @deprecated since Symfony 4.1, to be removed in 5.0
50
+
* @deprecated since Symfony 4.1
51
51
*/
52
52
constCHECK_DNS_TYPE_CNAME = 'CNAME';
53
53
54
54
/**
55
-
* @deprecated since Symfony 4.1, to be removed in 5.0
55
+
* @deprecated since Symfony 4.1
56
56
*/
57
57
constCHECK_DNS_TYPE_MX = 'MX';
58
58
59
59
/**
60
-
* @deprecated since Symfony 4.1, to be removed in 5.0
60
+
* @deprecated since Symfony 4.1
61
61
*/
62
62
constCHECK_DNS_TYPE_NAPTR = 'NAPTR';
63
63
64
64
/**
65
-
* @deprecated since Symfony 4.1, to be removed in 5.0
65
+
* @deprecated since Symfony 4.1
66
66
*/
67
67
constCHECK_DNS_TYPE_NS = 'NS';
68
68
69
69
/**
70
-
* @deprecated since Symfony 4.1, to be removed in 5.0
70
+
* @deprecated since Symfony 4.1
71
71
*/
72
72
constCHECK_DNS_TYPE_PTR = 'PTR';
73
73
74
74
/**
75
-
* @deprecated since Symfony 4.1, to be removed in 5.0
75
+
* @deprecated since Symfony 4.1
76
76
*/
77
77
constCHECK_DNS_TYPE_SOA = 'SOA';
78
78
79
79
/**
80
-
* @deprecated since Symfony 4.1, to be removed in 5.0
80
+
* @deprecated since Symfony 4.1
81
81
*/
82
82
constCHECK_DNS_TYPE_SRV = 'SRV';
83
83
84
84
/**
85
-
* @deprecated since Symfony 4.1, to be removed in 5.0
85
+
* @deprecated since Symfony 4.1
86
86
*/
87
87
constCHECK_DNS_TYPE_TXT = 'TXT';
88
88
@@ -95,13 +95,13 @@ class Url extends Constraint
95
95
public$message = 'This value is not a valid URL.';
96
96
97
97
/**
98
-
* @deprecated since Symfony 4.1, to be removed in 5.0
98
+
* @deprecated since Symfony 4.1
99
99
*/
100
100
public$dnsMessage = 'The host could not be resolved.';
101
101
public$protocols = array('http', 'https');
102
102
103
103
/**
104
-
* @deprecated since Symfony 4.1, to be removed in 5.0
104
+
* @deprecated since Symfony 4.1
105
105
*/
106
106
public$checkDNS = self::CHECK_DNS_TYPE_NONE;
107
107
public$relativeProtocol = false;
@@ -110,10 +110,10 @@ public function __construct($options = null)
110
110
{
111
111
if (is_array($options)) {
112
112
if (array_key_exists('checkDNS', $options)) {
113
-
@trigger_error(sprintf('The "checkDNS" option in "%s" is deprecated since Symfony 4.1 and will be removed in 5.0. Its false-positive rate is too high to be relied upon.', self::class), E_USER_DEPRECATED);
113
+
@trigger_error(sprintf('The "checkDNS" option in "%s" is deprecated since Symfony 4.1. Its false-positive rate is too high to be relied upon.', self::class), E_USER_DEPRECATED);
114
114
}
115
115
if (array_key_exists('dnsMessage', $options)) {
116
-
@trigger_error(sprintf('The "dnsMessage" option in "%s" is deprecated since Symfony 4.1 and will be removed in 5.0.', self::class), E_USER_DEPRECATED);
116
+
@trigger_error(sprintf('The "dnsMessage" option in "%s" is deprecated since Symfony 4.1.', self::class), E_USER_DEPRECATED);
Copy file name to clipboardExpand all lines: Tests/Constraints/EmailValidatorTest.php
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,7 @@ protected function createValidator()
27
27
}
28
28
29
29
/**
30
-
* @expectedDeprecation Calling `new Symfony\Component\Validator\Constraints\EmailValidator(true)` is deprecated since Symfony 4.1 and will be removed in 5.0, use `new Symfony\Component\Validator\Constraints\EmailValidator("strict")` instead.
30
+
* @expectedDeprecation Calling `new Symfony\Component\Validator\Constraints\EmailValidator(true)` is deprecated since Symfony 4.1, use `new Symfony\Component\Validator\Constraints\EmailValidator("strict")` instead.
@@ -226,8 +226,8 @@ public function testUnknownModesOnValidateTriggerException()
226
226
}
227
227
228
228
/**
229
-
* @expectedDeprecation The "strict" property is deprecated since Symfony 4.1 and will be removed in 5.0. Use "mode"=>"strict" instead.
230
-
* @expectedDeprecation The Symfony\Component\Validator\Constraints\Email::$strict property is deprecated since Symfony 4.1 and will be removed in 5.0. Use Symfony\Component\Validator\Constraints\Email::mode="strict" instead.
229
+
* @expectedDeprecation The "strict" property is deprecated since Symfony 4.1. Use "mode"=>"strict" instead.
230
+
* @expectedDeprecation The Symfony\Component\Validator\Constraints\Email::$strict property is deprecated since Symfony 4.1. Use Symfony\Component\Validator\Constraints\Email::mode="strict" instead.
Copy file name to clipboardExpand all lines: Tests/Constraints/UrlValidatorTest.php
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -265,7 +265,7 @@ public function getValidCustomUrls()
265
265
* @dataProvider getCheckDns
266
266
* @requires function Symfony\Bridge\PhpUnit\DnsMock::withMockedHosts
267
267
* @group legacy
268
-
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1 and will be removed in 5.0. Its false-positive rate is too high to be relied upon.
268
+
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1. Its false-positive rate is too high to be relied upon.
269
269
*/
270
270
publicfunctiontestCheckDns($violation)
271
271
{
@@ -297,7 +297,7 @@ public function getCheckDns()
297
297
* @dataProvider getCheckDnsTypes
298
298
* @requires function Symfony\Bridge\PhpUnit\DnsMock::withMockedHosts
299
299
* @group legacy
300
-
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1 and will be removed in 5.0. Its false-positive rate is too high to be relied upon.
300
+
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1. Its false-positive rate is too high to be relied upon.
301
301
*/
302
302
publicfunctiontestCheckDnsByType($type)
303
303
{
@@ -335,8 +335,8 @@ public function getCheckDnsTypes()
* @requires function Symfony\Bridge\PhpUnit\DnsMock::withMockedHosts
337
337
* @group legacy
338
-
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1 and will be removed in 5.0. Its false-positive rate is too high to be relied upon.
339
-
* @expectedDeprecation The "dnsMessage" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1 and will be removed in 5.0.
338
+
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1. Its false-positive rate is too high to be relied upon.
339
+
* @expectedDeprecation The "dnsMessage" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1.
340
340
*/
341
341
publicfunctiontestCheckDnsWithInvalidType()
342
342
{
@@ -352,7 +352,7 @@ public function testCheckDnsWithInvalidType()
352
352
353
353
/**
354
354
* @group legacy
355
-
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1 and will be removed in 5.0. Its false-positive rate is too high to be relied upon.
355
+
* @expectedDeprecation The "checkDNS" option in "Symfony\Component\Validator\Constraints\Url" is deprecated since Symfony 4.1. Its false-positive rate is too high to be relied upon.
0 commit comments