X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=lib%2Fjsonsearchresultslist.php;h=80d4036aad54694e851a4d84d6f2df215c5ddfe1;hb=1d29ba83150bdd7a23e497ca9a743ac2b6158b6f;hp=a315d0abd7b2a456407ebf14f92bc95ed385ab46;hpb=be5d113fc684fcbe41b8374c62bfeb0f267216b7;p=quix0rs-gnu-social.git diff --git a/lib/jsonsearchresultslist.php b/lib/jsonsearchresultslist.php index a315d0abd7..80d4036aad 100644 --- a/lib/jsonsearchresultslist.php +++ b/lib/jsonsearchresultslist.php @@ -27,7 +27,7 @@ * @link http://status.net/ */ -if (!defined('STATUSNET')) { +if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } @@ -101,12 +101,22 @@ class JSONSearchResultsList $this->max_id = (int)$this->notice->id; } + if ($this->since_id && $this->notice->id <= $this->since_id) { + break; + } + if ($cnt > $this->rpp) { break; } - $item = new ResultItem($this->notice); - array_push($this->results, $item); + $profile = $this->notice->getProfile(); + + // Don't show notices from deleted users + + if (!empty($profile)) { + $item = new ResultItem($this->notice); + array_push($this->results, $item); + } } $time_end = microtime(true);