Skip to content

Commit

Permalink
fix: cleanup state bridge with the legacy system (#4405)
Browse files Browse the repository at this point in the history
  • Loading branch information
dunglas committed Sep 1, 2021
1 parent 6b068db commit 1bf113e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
3 changes: 3 additions & 0 deletions src/State/LegacyDataPersisterProcessor.php
Expand Up @@ -18,6 +18,9 @@
use ApiPlatform\Core\DataPersister\ResumableDataPersisterInterface;
use ApiPlatform\Metadata\Operation;

/**
* @deprecated
*/
class LegacyDataPersisterProcessor implements ProcessorInterface
{
private $dataPersister;
Expand Down
8 changes: 1 addition & 7 deletions src/State/LegacyDataProviderState.php
Expand Up @@ -18,8 +18,6 @@
use ApiPlatform\Core\DataProvider\ItemDataProviderInterface;
use ApiPlatform\Core\DataProvider\RestrictedDataProviderInterface;
use ApiPlatform\Core\DataProvider\SubresourceDataProviderInterface;
use ApiPlatform\Metadata\Property\Factory\PropertyMetadataFactoryInterface;
use ApiPlatform\Metadata\Property\Factory\PropertyNameCollectionFactoryInterface;

/**
* @deprecated
Expand All @@ -29,16 +27,12 @@ final class LegacyDataProviderState implements ProviderInterface
private $itemDataProvider;
private $collectionDataProvider;
private $subresourceDataProvider;
private $propertyNameCollectionFactory;
private $propertyMetadataFactory;

public function __construct(ItemDataProviderInterface $itemDataProvider, CollectionDataProviderInterface $collectionDataProvider, SubresourceDataProviderInterface $subresourceDataProvider, PropertyNameCollectionFactoryInterface $propertyNameCollectionFactory, PropertyMetadataFactoryInterface $propertyMetadataFactory)
public function __construct(ItemDataProviderInterface $itemDataProvider, CollectionDataProviderInterface $collectionDataProvider, SubresourceDataProviderInterface $subresourceDataProvider)
{
$this->itemDataProvider = $itemDataProvider;
$this->collectionDataProvider = $collectionDataProvider;
$this->subresourceDataProvider = $subresourceDataProvider;
$this->propertyNameCollectionFactory = $propertyNameCollectionFactory;
$this->propertyMetadataFactory = $propertyMetadataFactory;
}

public function provide(string $resourceClass, array $identifiers = [], ?string $operationName = null, array $context = [])
Expand Down

0 comments on commit 1bf113e

Please sign in to comment.