Skip to content

Commit

Permalink
Improved SearchFacetsExtension Twig extension code
Browse files Browse the repository at this point in the history
  • Loading branch information
alongosz committed Nov 19, 2024
1 parent 3277755 commit b66fd44
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bundle/Twig/Extension/SearchFacetsExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public function getFilters(): array
return [
new TwigFilter(
'ibexa_choices_as_facets',
[$this, 'getChoicesAsFacets']
$this->getChoicesAsFacets(...)
),
];
}
Expand All @@ -46,7 +46,7 @@ public function getChoicesAsFacets(

if ($comparator === null) {
$comparator = static function (ChoiceView $choice, TermAggregationResultEntry $term): bool {
return $choice->data == $term->getKey();
return $choice->data === $term->getKey();
};
}

Expand Down

0 comments on commit b66fd44

Please sign in to comment.