Skip to content

Commit b2c5759

Browse files
committed
Merge 4.1
2 parents 98276c4 + bb9afb4 commit b2c5759

21 files changed

+923
-442
lines changed

core/bootstrap.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,12 @@ use ApiPlatform\Action\EntrypointAction;
2323
use ApiPlatform\Action\ExceptionAction;
2424
use ApiPlatform\Action\NotExposedAction;
2525
use ApiPlatform\Action\PlaceholderAction;
26-
use ApiPlatform\Api\IdentifiersExtractor;
27-
use ApiPlatform\Api\ResourceClassResolver;
28-
use ApiPlatform\Api\UriVariablesConverter;
29-
use ApiPlatform\Api\UriVariableTransformer\DateTimeUriVariableTransformer;
30-
use ApiPlatform\Api\UriVariableTransformer\IntegerUriVariableTransformer;
31-
use ApiPlatform\Api\UrlGeneratorInterface as ApiUrlGeneratorInterface;
26+
use ApiPlatform\Metadata\IdentifiersExtractor;
27+
use ApiPlatform\Metadata\ResourceClassResolver;
28+
use ApiPlatform\Metadata\UriVariablesConverter;
29+
use ApiPlatform\Metadata\UriVariableTransformer\DateTimeUriVariableTransformer;
30+
use ApiPlatform\Metadata\UriVariableTransformer\IntegerUriVariableTransformer;
31+
use ApiPlatform\Metadata\UrlGeneratorInterface as ApiUrlGeneratorInterface;
3232
use ApiPlatform\Symfony\Validator\EventListener\ValidationExceptionListener;
3333
use ApiPlatform\Documentation\DocumentationInterface;
3434
use ApiPlatform\Symfony\EventListener\AddFormatListener;

core/configuration.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -374,7 +374,7 @@ api_platform:
374374
host: ~
375375

376376
# The URL generation strategy to use for IRIs
377-
url_generation_strategy: !php/const ApiPlatform\Api\UrlGeneratorInterface::ABS_PATH
377+
url_generation_strategy: !php/const ApiPlatform\Metadata\UrlGeneratorInterface::ABS_PATH
378378

379379
# To enable collecting denormalization errors
380380
collectDenormalizationErrors: false
@@ -711,7 +711,7 @@ If you need to globally configure all the resources instead of adding configurat
711711
<?php
712712
// config/api-platform.php
713713

714-
use ApiPlatform\Api\UrlGeneratorInterface;
714+
use ApiPlatform\Metadata\UrlGeneratorInterface;
715715

716716
return [
717717
'defaults' => [

core/doctrine-filters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1268,7 +1268,7 @@ use ApiPlatform\Core\Annotation\ApiResource;
12681268
use App\Filter\CustomAndFilter;
12691269
12701270
#[ApiResource]
1271-
#[ApiFilter(CustomAndFilter::class, properties=["name", "cost"])]
1271+
#[ApiFilter(CustomAndFilter::class, properties: ['name', 'cost'])]
12721272
class Offer
12731273
{
12741274
// ...

core/extensions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,12 +77,12 @@ final readonly class CurrentUserExtension implements QueryCollectionExtensionInt
7777
{
7878
}
7979

80-
public function applyToCollection(QueryBuilder $queryBuilder, QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, Operation $operation = null, array $context = []): void
80+
public function applyToCollection(QueryBuilder $queryBuilder, QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, ?Operation $operation = null, array $context = []): void
8181
{
8282
$this->addWhere($queryBuilder, $resourceClass);
8383
}
8484

85-
public function applyToItem(QueryBuilder $queryBuilder, QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, array $identifiers, Operation $operation = null, array $context = []): void
85+
public function applyToItem(QueryBuilder $queryBuilder, QueryNameGeneratorInterface $queryNameGenerator, string $resourceClass, array $identifiers, ?Operation $operation = null, array $context = []): void
8686
{
8787
$this->addWhere($queryBuilder, $resourceClass);
8888
}

0 commit comments

Comments
 (0)