Skip to content

Commit

Permalink
PHP 7.2: count()
Browse files Browse the repository at this point in the history
fix - Parameter must be an array or an object that implements Countable
  • Loading branch information
vitaliytv authored Apr 6, 2018
1 parent ca85260 commit 4880619
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Doctrine/Query/Abstract.php
Original file line number Diff line number Diff line change
Expand Up @@ -1384,7 +1384,7 @@ public function whereIn($expr, $params = array(), $not = false)
public function andWhereIn($expr, $params = array(), $not = false)
{
// if there's no params, return (else we'll get a WHERE IN (), invalid SQL)
if (isset($params) and (count($params) == 0)) {
if (isset($params) and is_array($params) and (count($params) == 0)) {
return $this;
}

Expand Down

0 comments on commit 4880619

Please sign in to comment.