diff --git a/src/Class/Service/FieldCollection/LayoutDefinitionService.php b/src/Class/Service/FieldCollection/LayoutDefinitionService.php index e5ca7b4a..77498797 100644 --- a/src/Class/Service/FieldCollection/LayoutDefinitionService.php +++ b/src/Class/Service/FieldCollection/LayoutDefinitionService.php @@ -24,9 +24,9 @@ use Pimcore\Bundle\StudioBackendBundle\Class\Hydrator\FieldCollection\LayoutDefinitionHydratorInterface; use Pimcore\Bundle\StudioBackendBundle\Class\Schema\FieldCollection\LayoutDefinition; use Pimcore\Bundle\StudioBackendBundle\Exception\Api\NotFoundException; -use Pimcore\Model\DataObject; use Pimcore\Model\DataObject\ClassDefinitionInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface; +use Pimcore\Model\DataObject\ClassDefinition\Data\Fieldcollections; /** * @internal @@ -91,7 +91,7 @@ private function getLayoutDefinitionByType(string $name): LayoutDefinition private function collectFieldCollectionTypes(ClassDefinitionInterface $classDefinition): void { foreach ($classDefinition->getFieldDefinitions() as $fieldDefinition) { - if ($fieldDefinition instanceof DataObject\ClassDefinition\Data\Fieldcollections) { + if ($fieldDefinition instanceof Fieldcollections) { $this->fieldCollectionTypes = [...$this->fieldCollectionTypes, ...$fieldDefinition->getAllowedTypes()]; } } diff --git a/src/Class/Service/ObjectBrick/LayoutDefinitionService.php b/src/Class/Service/ObjectBrick/LayoutDefinitionService.php index 689dfa0b..11120029 100644 --- a/src/Class/Service/ObjectBrick/LayoutDefinitionService.php +++ b/src/Class/Service/ObjectBrick/LayoutDefinitionService.php @@ -24,9 +24,9 @@ use Pimcore\Bundle\StudioBackendBundle\Class\Hydrator\ObjectBrick\LayoutDefinitionHydratorInterface; use Pimcore\Bundle\StudioBackendBundle\Class\Schema\ObjectBrick\LayoutDefinition; use Pimcore\Bundle\StudioBackendBundle\Exception\Api\NotFoundException; -use Pimcore\Model\DataObject; use Pimcore\Model\DataObject\ClassDefinitionInterface; use Symfony\Component\EventDispatcher\EventDispatcherInterface; +use Pimcore\Model\DataObject\ClassDefinition\Data\Objectbricks; /** * @internal @@ -88,7 +88,7 @@ private function getLayoutDefinitionByType(string $name): LayoutDefinition private function collectFieldCollectionTypes(ClassDefinitionInterface $classDefinition): void { foreach ($classDefinition->getFieldDefinitions() as $fieldDefinition) { - if ($fieldDefinition instanceof DataObject\ClassDefinition\Data\Objectbricks) { + if ($fieldDefinition instanceof Objectbricks) { $this->objectBrickTypes = [...$this->objectBrickTypes, ...$fieldDefinition->getAllowedTypes()]; } }