From 301b02a23e2a0ae00c09a88a390272127a1c4906 Mon Sep 17 00:00:00 2001 From: Sebastian Blank Date: Wed, 6 Nov 2024 14:17:07 +0100 Subject: [PATCH] getValueForObject/getValueFromObjectBrick returns mixed --- src/GraphQL/Service.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/GraphQL/Service.php b/src/GraphQL/Service.php index b52fb5e4..36b1ceeb 100644 --- a/src/GraphQL/Service.php +++ b/src/GraphQL/Service.php @@ -786,7 +786,7 @@ public function getPropertyTypeDefinition($typeName) * @param array|null $brickDescriptor * @param array $args * - * @return stdclass, value and objectid where the value comes from + * @return mixed */ public static function getValueForObject($object, $key, $brickType = null, $brickKey = null, $fieldDefinition = null, $context = [], $brickDescriptor = null, $args = []) { @@ -1167,7 +1167,7 @@ public static function getValueFromObjectBrick( string $brickKey, ?array $brickDescriptor = null, array $descriptorData = [], - ): stdClass|array|null { + ): mixed { $context = ['object' => $object]; $key = \Pimcore\Model\DataObject\Service::getFieldForBrickType($object->getclass(), $brickType); @@ -1191,7 +1191,8 @@ public static function getValueFromObjectBrick( $def, $context, $brickDescriptor, - $descriptorData['args'] ?? []); + $descriptorData['args'] ?? [] + ); } return null;