From 593de9e34f914b374fe90400e6cb7f14f0e341a4 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Sat, 4 Mar 2023 14:50:52 -0700 Subject: [PATCH] Update SearchApiV2Service, order hashtag results by cached_count --- app/Services/SearchApiV2Service.php | 1 + 1 file changed, 1 insertion(+) diff --git a/app/Services/SearchApiV2Service.php b/app/Services/SearchApiV2Service.php index 64c8303e7..a6826b77e 100644 --- a/app/Services/SearchApiV2Service.php +++ b/app/Services/SearchApiV2Service.php @@ -131,6 +131,7 @@ class SearchApiV2Service return $q->where('can_search', true) ->orWhereNull('can_search'); }) + ->orderByDesc('cached_count') ->offset($offset) ->limit($limit) ->get()