diff --git a/src/Searcher.php b/src/Searcher.php index cf63ef9..f23e730 100755 --- a/src/Searcher.php +++ b/src/Searcher.php @@ -341,7 +341,7 @@ public function getSearch($search, $orderBy = null, $orderAs = null) if(!$this->subJoined){ - if(count($order) > 0) + if(isset($order) && count($order) > 0) { $last_order = null; foreach($order as $curOrder)