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/Callback.php
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -39,16 +39,16 @@ class Callback extends Constraint
39
39
publicfunction__construct($options = null)
40
40
{
41
41
// Invocation through annotations with an array parameter only
42
-
if (is_array($options) && 1 === count($options) && isset($options['value'])) {
42
+
if (\is_array($options) && 1 === \count($options) && isset($options['value'])) {
43
43
$options = $options['value'];
44
44
}
45
45
46
-
if (is_array($options) && isset($options['methods'])) {
46
+
if (\is_array($options) && isset($options['methods'])) {
47
47
@trigger_error('The "methods" option of the '.__CLASS__.' class is deprecated since Symfony 2.4 and will be removed in 3.0. Use the "callback" option instead.', E_USER_DEPRECATED);
thrownewConstraintDefinitionException(sprintf('Method "%s" targeted by Callback constraint does not exist in class %s', $method, get_class($object)));
64
+
thrownewConstraintDefinitionException(sprintf('Method "%s" targeted by Callback constraint does not exist in class %s', $method, \get_class($object)));
65
65
}
66
66
67
67
$reflMethod = new \ReflectionMethod($object, $method);
0 commit comments