refactor search a little and add much better testing
This commit is contained in:
@ -420,7 +420,7 @@ class OuroborosAPI extends Extension
|
||||
protected function postIndex(int $limit, int $page, array $tags)
|
||||
{
|
||||
$start = ($page - 1) * $limit;
|
||||
$results = Image::find_images(max($start, 0), min($limit, 100), $tags);
|
||||
$results = Search::find_images(max($start, 0), min($limit, 100), $tags);
|
||||
$posts = [];
|
||||
foreach ($results as $img) {
|
||||
if (!is_object($img)) {
|
||||
|
Reference in New Issue
Block a user