Skip to content

Commit dd05a18

Browse files
Merge branch '3.4' into 4.4
* 3.4: Enable "native_constant_invocation" CS rule Make AbstractPhpFileCacheWarmer public
2 parents 376bd3a + 0edf31d commit dd05a18

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

OptionsResolver.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -854,7 +854,7 @@ public function offsetGet($option/*, bool $triggerDeprecation = true*/)
854854
// Shortcut for resolved options
855855
if (isset($this->resolved[$option]) || \array_key_exists($option, $this->resolved)) {
856856
if ($triggerDeprecation && isset($this->deprecated[$option]) && (isset($this->given[$option]) || $this->calling) && \is_string($this->deprecated[$option])) {
857-
@trigger_error(strtr($this->deprecated[$option], ['%name%' => $option]), E_USER_DEPRECATED);
857+
@trigger_error(strtr($this->deprecated[$option], ['%name%' => $option]), \E_USER_DEPRECATED);
858858
}
859859

860860
return $this->resolved[$option];
@@ -1013,7 +1013,7 @@ public function offsetGet($option/*, bool $triggerDeprecation = true*/)
10131013
}
10141014

10151015
if ('' !== $deprecationMessage) {
1016-
@trigger_error(strtr($deprecationMessage, ['%name%' => $option]), E_USER_DEPRECATED);
1016+
@trigger_error(strtr($deprecationMessage, ['%name%' => $option]), \E_USER_DEPRECATED);
10171017
}
10181018
}
10191019

Tests/OptionsResolverTest.php

+7-7
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,7 @@ function (OptionsResolver $resolver) {
549549
},
550550
['foo' => 'baz'],
551551
[
552-
'type' => E_USER_DEPRECATED,
552+
'type' => \E_USER_DEPRECATED,
553553
'message' => 'The option "foo" is deprecated.',
554554
],
555555
1,
@@ -567,7 +567,7 @@ function (OptionsResolver $resolver) {
567567
},
568568
['foo' => 'baz'],
569569
[
570-
'type' => E_USER_DEPRECATED,
570+
'type' => \E_USER_DEPRECATED,
571571
'message' => 'The option "foo" is deprecated, use "bar" option instead.',
572572
],
573573
2,
@@ -587,7 +587,7 @@ function (OptionsResolver $resolver) {
587587
},
588588
[],
589589
[
590-
'type' => E_USER_DEPRECATED,
590+
'type' => \E_USER_DEPRECATED,
591591
'message' => 'The option "foo" is deprecated.',
592592
],
593593
1,
@@ -609,7 +609,7 @@ function (OptionsResolver $resolver) {
609609
},
610610
['foo' => new \stdClass()],
611611
[
612-
'type' => E_USER_DEPRECATED,
612+
'type' => \E_USER_DEPRECATED,
613613
'message' => 'Passing an instance of "stdClass" to option "foo" is deprecated, pass its FQCN instead.',
614614
],
615615
1,
@@ -645,7 +645,7 @@ function (OptionsResolver $resolver) {
645645
},
646646
['foo' => null], // It triggers a deprecation
647647
[
648-
'type' => E_USER_DEPRECATED,
648+
'type' => \E_USER_DEPRECATED,
649649
'message' => 'Passing a value different than true or false is deprecated.',
650650
],
651651
1,
@@ -681,7 +681,7 @@ function (OptionsResolver $resolver) {
681681
},
682682
['widget' => 'single_text', 'date_format' => 2],
683683
[
684-
'type' => E_USER_DEPRECATED,
684+
'type' => \E_USER_DEPRECATED,
685685
'message' => 'Using the "date_format" option when the "widget" option is set to "single_text" is deprecated.',
686686
],
687687
1,
@@ -707,7 +707,7 @@ function (OptionsResolver $resolver) {
707707
},
708708
['foo' => 'baz'], // It triggers a deprecation
709709
[
710-
'type' => E_USER_DEPRECATED,
710+
'type' => \E_USER_DEPRECATED,
711711
'message' => 'The option "foo" is deprecated.',
712712
],
713713
4,

0 commit comments

Comments
 (0)