mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
Fix CountryOfBirthAggregator: allow to receive null data in getLabels method
This commit is contained in:
parent
b36e37d9c5
commit
b9231a91a3
@ -36,7 +36,7 @@ final readonly class CountryOfBirthAggregator implements AggregatorInterface, Ex
|
||||
return null;
|
||||
}
|
||||
|
||||
public function alterQuery(QueryBuilder $qb, $data)
|
||||
public function alterQuery(QueryBuilder $qb, $data): void
|
||||
{
|
||||
// add a clause in select part
|
||||
if ('country' === $data['group_by_level']) {
|
||||
@ -139,7 +139,7 @@ final readonly class CountryOfBirthAggregator implements AggregatorInterface, Ex
|
||||
];
|
||||
}
|
||||
|
||||
return static fn (string $value): string => $labels[$value];
|
||||
return static fn (?string $value): string => $labels[(string) $value];
|
||||
}
|
||||
|
||||
public function getQueryKeys($data)
|
||||
|
Loading…
x
Reference in New Issue
Block a user