diff --git a/PiResults/LastSearchesCommand.php b/PiResults/LastSearchesCommand.php index 6036bad1..7175d911 100644 --- a/PiResults/LastSearchesCommand.php +++ b/PiResults/LastSearchesCommand.php @@ -69,8 +69,13 @@ public function execute() { return NULL; } + $lastSearches = $this->getLastSearches(); + if(empty($lastSearches)) { + return NULL; + } + $marker = array( - 'loop_lastsearches|lastsearch' => $this->getLastSearches() + 'loop_lastsearches|lastsearch' => $lastSearches ); return $marker; @@ -160,4 +165,4 @@ protected function getLastSearchesFromDatabase($limit = FALSE) { include_once($GLOBALS['TYPO3_CONF_VARS'][TYPO3_MODE]['XCLASS']['ext/solr/PiResults/LastSearchesCommand.php']); } -?> \ No newline at end of file +?>