Skip to content

Commit

Permalink
fix: category id needs to be casted to string for trim function (#205)
Browse files Browse the repository at this point in the history
  • Loading branch information
MercuryKojo authored Oct 15, 2024
1 parent ee56647 commit 245c9a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/FilterService/FilterType/MultiSelectCategory.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public function addCondition(AbstractFilterDefinitionType $filterDefinition, Pro
$category = $category->getId();
}

$category = '%,' . trim($category) . ',%';
$category = '%,' . trim((string)$category) . ',%';

$conditions[] = $filterDefinition->getField() . ' LIKE ' . $db->quote($category);
}
Expand Down

0 comments on commit 245c9a7

Please sign in to comment.