We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
@@ -20,14 +20,14 @@ discard block |
||
20 | 20 | return [ |
21 | 21 | new ExpressionFunction( |
22 | 22 | 'hasRole', |
23 | - function ($role) { |
|
23 | + function($role) { |
|
24 | 24 | return sprintf('$container->get(\'security.authorization_checker\')->isGranted(%s)', $role); |
25 | 25 | } |
26 | 26 | ), |
27 | 27 | |
28 | 28 | new ExpressionFunction( |
29 | 29 | 'hasAnyRole', |
30 | - function ($roles) { |
|
30 | + function($roles) { |
|
31 | 31 | $code = sprintf('array_reduce(%s, function ($isGranted, $role) use ($container) { return $isGranted || $container->get(\'security.authorization_checker\')->isGranted($role); }, false)', $roles); |
32 | 32 | |
33 | 33 | return $code; |
@@ -36,35 +36,35 @@ discard block |
||
36 | 36 | |
37 | 37 | new ExpressionFunction( |
38 | 38 | 'isAnonymous', |
39 | - function () { |
|
39 | + function() { |
|
40 | 40 | return '$container->get(\'security.authorization_checker\')->isGranted(\'IS_AUTHENTICATED_ANONYMOUSLY\')'; |
41 | 41 | } |
42 | 42 | ), |
43 | 43 | |
44 | 44 | new ExpressionFunction( |
45 | 45 | 'isRememberMe', |
46 | - function () { |
|
46 | + function() { |
|
47 | 47 | return '$container->get(\'security.authorization_checker\')->isGranted(\'IS_AUTHENTICATED_REMEMBERED\')'; |
48 | 48 | } |
49 | 49 | ), |
50 | 50 | |
51 | 51 | new ExpressionFunction( |
52 | 52 | 'isFullyAuthenticated', |
53 | - function () { |
|
53 | + function() { |
|
54 | 54 | return '$container->get(\'security.authorization_checker\')->isGranted(\'IS_AUTHENTICATED_FULLY\')'; |
55 | 55 | } |
56 | 56 | ), |
57 | 57 | |
58 | 58 | new ExpressionFunction( |
59 | 59 | 'isAuthenticated', |
60 | - function () { |
|
60 | + function() { |
|
61 | 61 | return '$container->get(\'security.authorization_checker\')->isGranted(\'IS_AUTHENTICATED_REMEMBERED\') || $container->get(\'security.authorization_checker\')->isGranted(\'IS_AUTHENTICATED_FULLY\')'; |
62 | 62 | } |
63 | 63 | ), |
64 | 64 | |
65 | 65 | new ExpressionFunction( |
66 | 66 | 'hasPermission', |
67 | - function ($object, $permission) { |
|
67 | + function($object, $permission) { |
|
68 | 68 | $code = sprintf('$container->get(\'security.authorization_checker\')->isGranted(%s, %s)', $permission, $object); |
69 | 69 | |
70 | 70 | return $code; |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | |
74 | 74 | new ExpressionFunction( |
75 | 75 | 'hasAnyPermission', |
76 | - function ($object, $permissions) { |
|
76 | + function($object, $permissions) { |
|
77 | 77 | $code = sprintf('array_reduce(%s, function ($isGranted, $permission) use ($container, $object) { return $isGranted || $container->get(\'security.authorization_checker\')->isGranted($permission, %s); }, false)', $permissions, $object); |
78 | 78 | |
79 | 79 | return $code; |
@@ -58,10 +58,10 @@ |
||
58 | 58 | /** @var \React\Promise\PromiseInterface $reactPromise */ |
59 | 59 | $reactPromise = $promise->adoptedPromise; |
60 | 60 | |
61 | - $reactPromise->then(function ($values) use (&$resolvedValue, &$wait) { |
|
61 | + $reactPromise->then(function($values) use (&$resolvedValue, &$wait) { |
|
62 | 62 | $resolvedValue = $values; |
63 | 63 | $wait = false; |
64 | - }, function ($reason) use (&$exception, &$wait) { |
|
64 | + }, function($reason) use (&$exception, &$wait) { |
|
65 | 65 | $exception = $reason; |
66 | 66 | $wait = false; |
67 | 67 | }); |