@@ -9,7 +9,7 @@ |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Operation; |
| 15 | 15 | |
@@ -9,7 +9,7 @@ |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Operation; |
| 15 | 15 | |
@@ -9,7 +9,7 @@ |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Operation; |
| 15 | 15 | |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Api; |
| 15 | 15 | |
@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | */ |
| 48 | 48 | public function getIdentifiersFromItem($item): array |
| 49 | 49 | { |
| 50 | - $keys = $this->getKeys($item, function ($item) use (&$identifiers) { |
|
| 50 | + $keys = $this->getKeys($item, function($item) use (&$identifiers) { |
|
| 51 | 51 | return $identifiers = $this->decorated->getIdentifiersFromItem($item); |
| 52 | 52 | }); |
| 53 | 53 | |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\EventListener; |
| 15 | 15 | |
@@ -133,7 +133,7 @@ discard block |
||
| 133 | 133 | } |
| 134 | 134 | |
| 135 | 135 | $identifiers = []; |
| 136 | - foreach ($attributes['subresource_context']['identifiers'] as $key => list($id, , $hasIdentifier)) { |
|
| 136 | + foreach ($attributes['subresource_context']['identifiers'] as $key => list($id,, $hasIdentifier)) { |
|
| 137 | 137 | if (true === $hasIdentifier) { |
| 138 | 138 | $identifiers[$id] = $request->attributes->get($id); |
| 139 | 139 | } |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Security\EventListener; |
| 15 | 15 | |
@@ -107,7 +107,7 @@ discard block |
||
| 107 | 107 | 'user' => $token->getUser(), |
| 108 | 108 | 'object' => $request->attributes->get('data'), |
| 109 | 109 | 'request' => $request, |
| 110 | - 'roles' => array_map(function (Role $role) { |
|
| 110 | + 'roles' => array_map(function(Role $role) { |
|
| 111 | 111 | return $role->getRole(); |
| 112 | 112 | }, $roles), |
| 113 | 113 | 'trust_resolver' => $this->authenticationTrustResolver, |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Security; |
| 15 | 15 | |
@@ -29,9 +29,9 @@ discard block |
||
| 29 | 29 | { |
| 30 | 30 | parent::registerFunctions(); |
| 31 | 31 | |
| 32 | - $this->register('is_granted', function ($attributes, $object = 'null') { |
|
| 32 | + $this->register('is_granted', function($attributes, $object = 'null') { |
|
| 33 | 33 | return sprintf('$auth_checker->isGranted(%s, %s)', $attributes, $object); |
| 34 | - }, function (array $variables, $attributes, $object = null) { |
|
| 34 | + }, function(array $variables, $attributes, $object = null) { |
|
| 35 | 35 | return $variables['auth_checker']->isGranted($attributes, $object); |
| 36 | 36 | }); |
| 37 | 37 | } |
@@ -89,8 +89,8 @@ discard block |
||
| 89 | 89 | ->arrayNode('swagger') |
| 90 | 90 | ->addDefaultsIfNotSet() |
| 91 | 91 | ->children() |
| 92 | - ->arrayNode('api_keys') |
|
| 93 | - ->prototype('array') |
|
| 92 | + ->arrayNode('api_keys') |
|
| 93 | + ->prototype('array') |
|
| 94 | 94 | ->children() |
| 95 | 95 | ->scalarNode('name') |
| 96 | 96 | ->info('The name of the header or query parameter containing the api key.') |
@@ -100,7 +100,7 @@ discard block |
||
| 100 | 100 | ->values(['query', 'header']) |
| 101 | 101 | ->end() |
| 102 | 102 | ->end() |
| 103 | - ->end() |
|
| 103 | + ->end() |
|
| 104 | 104 | ->end() |
| 105 | 105 | ->end() |
| 106 | 106 | ->end() |
@@ -9,7 +9,7 @@ discard block |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Bridge\Symfony\Bundle\DependencyInjection; |
| 15 | 15 | |
@@ -56,7 +56,7 @@ discard block |
||
| 56 | 56 | ->defaultValue('0.0.0') |
| 57 | 57 | ->end() |
| 58 | 58 | ->scalarNode('default_operation_path_resolver') |
| 59 | - ->beforeNormalization()->always(function ($v) { |
|
| 59 | + ->beforeNormalization()->always(function($v) { |
|
| 60 | 60 | @trigger_error('The use of the `default_operation_path_resolver` has been deprecated in 2.1 and will be removed in 3.0. Use `path_segment_name_generator` instead.', E_USER_DEPRECATED); |
| 61 | 61 | |
| 62 | 62 | return $v; |
@@ -212,7 +212,7 @@ discard block |
||
| 212 | 212 | ->useAttributeAsKey('exception_class') |
| 213 | 213 | ->beforeNormalization() |
| 214 | 214 | ->ifArray() |
| 215 | - ->then(function (array $exceptionToStatus) { |
|
| 215 | + ->then(function(array $exceptionToStatus) { |
|
| 216 | 216 | foreach ($exceptionToStatus as &$httpStatusCode) { |
| 217 | 217 | if (\is_int($httpStatusCode)) { |
| 218 | 218 | continue; |
@@ -231,7 +231,7 @@ discard block |
||
| 231 | 231 | ->prototype('integer')->end() |
| 232 | 232 | ->validate() |
| 233 | 233 | ->ifArray() |
| 234 | - ->then(function (array $exceptionToStatus) { |
|
| 234 | + ->then(function(array $exceptionToStatus) { |
|
| 235 | 235 | foreach ($exceptionToStatus as $httpStatusCode) { |
| 236 | 236 | if ($httpStatusCode < 100 || $httpStatusCode >= 600) { |
| 237 | 237 | throw new InvalidConfigurationException(sprintf('The HTTP status code "%s" is not valid.', $httpStatusCode)); |
@@ -263,7 +263,7 @@ discard block |
||
| 263 | 263 | ->useAttributeAsKey('format') |
| 264 | 264 | ->beforeNormalization() |
| 265 | 265 | ->ifArray() |
| 266 | - ->then(function ($v) { |
|
| 266 | + ->then(function($v) { |
|
| 267 | 267 | foreach ($v as $format => $value) { |
| 268 | 268 | if (isset($value['mime_types'])) { |
| 269 | 269 | continue; |
@@ -9,7 +9,7 @@ |
||
| 9 | 9 | * file that was distributed with this source code. |
| 10 | 10 | */ |
| 11 | 11 | |
| 12 | -declare(strict_types=1); |
|
| 12 | +declare(strict_types = 1); |
|
| 13 | 13 | |
| 14 | 14 | namespace ApiPlatform\Core\Bridge\Doctrine\Orm\Util; |
| 15 | 15 | |