mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-29 10:05:03 +00:00
Implements return types on aggregators
This commit is contained in:
@@ -19,7 +19,7 @@ trait ExportDataNormalizerTrait
|
||||
/**
|
||||
* @param object|list<object> $entity
|
||||
*/
|
||||
public function normalizeDoctrineEntity(object|array $entity): array|int
|
||||
public function normalizeDoctrineEntity(object|array|null $entity): array|int
|
||||
{
|
||||
if (is_array($entity)) {
|
||||
return array_values(array_filter(array_map(static fn (object $entity) => $entity->getId(), $entity), fn ($value) => null !== $value));
|
||||
|
@@ -141,7 +141,7 @@ class SortExportElementTest extends KernelTestCase
|
||||
return [];
|
||||
}
|
||||
|
||||
public function getLabels($key, array $values, mixed $data)
|
||||
public function getLabels($key, array $values, mixed $data): callable
|
||||
{
|
||||
return fn ($v) => $v;
|
||||
}
|
||||
|
Reference in New Issue
Block a user