@@ -201,7 +201,7 @@ |
||
201 | 201 | * @param string|null $format |
202 | 202 | * @param array $context |
203 | 203 | * |
204 | - * @return bool|string |
|
204 | + * @return string|false |
|
205 | 205 | */ |
206 | 206 | private function getHalCacheKey(string $format = null, array $context) |
207 | 207 | { |
@@ -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\Hal\Serializer; |
15 | 15 |
@@ -177,7 +177,7 @@ discard block |
||
177 | 177 | |
178 | 178 | /** |
179 | 179 | * @param \ArrayObject $pathOperation |
180 | - * @param array $mimeTypes |
|
180 | + * @param string[] $mimeTypes |
|
181 | 181 | * @param string $operationType |
182 | 182 | * @param ResourceMetadata $resourceMetadata |
183 | 183 | * @param string $resourceClass |
@@ -232,7 +232,7 @@ discard block |
||
232 | 232 | |
233 | 233 | /** |
234 | 234 | * @param \ArrayObject $pathOperation |
235 | - * @param array $mimeTypes |
|
235 | + * @param string[] $mimeTypes |
|
236 | 236 | * @param string $operationType |
237 | 237 | * @param ResourceMetadata $resourceMetadata |
238 | 238 | * @param string $resourceClass |
@@ -267,7 +267,7 @@ discard block |
||
267 | 267 | |
268 | 268 | /** |
269 | 269 | * @param \ArrayObject $pathOperation |
270 | - * @param array $mimeTypes |
|
270 | + * @param string[] $mimeTypes |
|
271 | 271 | * @param string $operationType |
272 | 272 | * @param ResourceMetadata $resourceMetadata |
273 | 273 | * @param string $resourceClass |
@@ -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\Swagger\Serializer; |
15 | 15 | |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | /** |
66 | 66 | * @param ContainerInterface|FilterCollection|null $filterLocator The new filter locator or the deprecated filter collection |
67 | 67 | */ |
68 | - public function __construct(ResourceMetadataFactoryInterface $resourceMetadataFactory, PropertyNameCollectionFactoryInterface $propertyNameCollectionFactory, PropertyMetadataFactoryInterface $propertyMetadataFactory, ResourceClassResolverInterface $resourceClassResolver, OperationMethodResolverInterface $operationMethodResolver, OperationPathResolverInterface $operationPathResolver, UrlGeneratorInterface $urlGenerator = null, $filterLocator = null, NameConverterInterface $nameConverter = null, $oauthEnabled = false, ?string $oauthType = '', ?string $oauthFlow = '', ?string $oauthTokenUrl = '', ?string $oauthAuthorizationUrl = '', array $oauthScopes = [], array $apiKeys = [], SubresourceOperationFactoryInterface $subresourceOperationFactory = null) |
|
68 | + public function __construct(ResourceMetadataFactoryInterface $resourceMetadataFactory, PropertyNameCollectionFactoryInterface $propertyNameCollectionFactory, PropertyMetadataFactoryInterface $propertyMetadataFactory, ResourceClassResolverInterface $resourceClassResolver, OperationMethodResolverInterface $operationMethodResolver, OperationPathResolverInterface $operationPathResolver, UrlGeneratorInterface $urlGenerator = null, $filterLocator = null, NameConverterInterface $nameConverter = null, $oauthEnabled = false, ? string $oauthType = '', ? string $oauthFlow = '', ? string $oauthTokenUrl = '', ? string $oauthAuthorizationUrl = '', array $oauthScopes = [], array $apiKeys = [], SubresourceOperationFactoryInterface $subresourceOperationFactory = null) |
|
69 | 69 | { |
70 | 70 | if ($urlGenerator) { |
71 | 71 | @trigger_error(sprintf('Passing an instance of %s to %s() is deprecated since version 2.1 and will be removed in 3.0.', UrlGeneratorInterface::class, __METHOD__), E_USER_DEPRECATED); |
@@ -135,7 +135,7 @@ discard block |
||
135 | 135 | $parametersMemory = []; |
136 | 136 | $pathOperation['parameters'] = []; |
137 | 137 | |
138 | - foreach ($subresourceOperation['identifiers'] as list($identifier, , $hasIdentifier)) { |
|
138 | + foreach ($subresourceOperation['identifiers'] as list($identifier,, $hasIdentifier)) { |
|
139 | 139 | if (true === $hasIdentifier) { |
140 | 140 | $pathOperation['parameters'][] = ['name' => $identifier, 'in' => 'path', 'required' => true, 'type' => 'string']; |
141 | 141 | $parametersMemory[] = $identifier; |
@@ -426,7 +426,7 @@ discard block |
||
426 | 426 | $definitionKey = $this->getDefinitionKey($resourceMetadata->getShortName(), (array) ($serializerContext['groups'] ?? [])); |
427 | 427 | |
428 | 428 | if (!isset($definitions[$definitionKey])) { |
429 | - $definitions[$definitionKey] = []; // Initialize first to prevent infinite loop |
|
429 | + $definitions[$definitionKey] = []; // Initialize first to prevent infinite loop |
|
430 | 430 | $definitions[$definitionKey] = $this->getDefinitionSchema($resourceClass, $resourceMetadata, $definitions, $serializerContext); |
431 | 431 | } |
432 | 432 |
@@ -211,7 +211,7 @@ |
||
211 | 211 | * |
212 | 212 | * @param string $property |
213 | 213 | * |
214 | - * @return array |
|
214 | + * @return string |
|
215 | 215 | */ |
216 | 216 | protected function splitPropertyParts(string $property/*, string $resourceClass*/): array |
217 | 217 | { |
@@ -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\Filter; |
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\Hal\Serializer; |
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\Documentation; |
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\Documentation\Action; |
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\Annotation; |
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\Hydra\EventListener; |
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\Hydra\Serializer; |
15 | 15 |