Skip to content

Commit

Permalink
Use Closure instance check.
Browse files Browse the repository at this point in the history
  • Loading branch information
Warxcell committed May 4, 2022
1 parent 35f62f0 commit 53034ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Filters.php
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public function appendFilter(QueryBuilder $queryBuilder, string $alias, string $
return false;
}

if (count($values) === 1 && is_callable($values[0])) {
if (count($values) === 1 && $values[0] instanceof \Closure) {
call_user_func_array($values[0], [$queryBuilder, $alias]);
} else {
$filter = $this->getFilter($filterName);
Expand Down

0 comments on commit 53034ef

Please sign in to comment.