From b38ef8ecea26c037b5d8a575c7b66b007a7e08fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20B=C3=B6hmer?= Date: Sat, 22 Feb 2025 21:12:58 +0100 Subject: [PATCH] Revert "Fixed type error introduced with api-platform upgrade" This reverts commit a54c2db9b932ebcd8ecff0d09326bb6cd20fb6a0. --- .../APIPlatform/DetermineTypeFromElementIRIDenormalizer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Serializer/APIPlatform/DetermineTypeFromElementIRIDenormalizer.php b/src/Serializer/APIPlatform/DetermineTypeFromElementIRIDenormalizer.php index 60508850..8283dbbe 100644 --- a/src/Serializer/APIPlatform/DetermineTypeFromElementIRIDenormalizer.php +++ b/src/Serializer/APIPlatform/DetermineTypeFromElementIRIDenormalizer.php @@ -24,7 +24,7 @@ declare(strict_types=1); namespace App\Serializer\APIPlatform; use ApiPlatform\Metadata\Exception\ResourceClassNotFoundException; -use ApiPlatform\Metadata\IriConverterInterface; +use ApiPlatform\Api\IriConverterInterface; use ApiPlatform\Metadata\Operation; use ApiPlatform\Metadata\Post; use ApiPlatform\Metadata\Resource\Factory\ResourceMetadataCollectionFactoryInterface; @@ -60,6 +60,7 @@ class DetermineTypeFromElementIRIDenormalizer implements DenormalizerInterface, * @param array $input * @param Operation $operation * @return array + * @throws ResourceClassNotFoundException */ private function addTypeDiscriminatorIfNecessary(array $input, Operation $operation): array { @@ -80,7 +81,6 @@ class DetermineTypeFromElementIRIDenormalizer implements DenormalizerInterface, } //Retrieve the element - //@phpstan-ignore-next-line $element = $this->iriConverter->getResourceFromIri($input['element']); //Retrieve the short name of the operation