Skip to content

Commit

Permalink
fixbug
Browse files Browse the repository at this point in the history
  • Loading branch information
huangbule committed Apr 23, 2024
1 parent 626fa92 commit e6c7bb4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Traits/FilterTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,9 @@ private function halfOpenFilter($qr, $column, $param)
if (count($arr) != 2)
throw new InvalidArgumentException($column . " corresponding values must be throughput or comma separated.");

return $qr->where($column, '>=', $arr[0])->where($column, '<', $arr[1]);
if (!empty($arr[0]) && !empty($arr[1])) {
return $qr->where($column, '>=', $arr[0])->where($column, '<', $arr[1]);
}
}

}

0 comments on commit e6c7bb4

Please sign in to comment.