From 3fa85e9fe7fb5139a14a0573475b0c868f49589c Mon Sep 17 00:00:00 2001 From: Josef Citrine Date: Thu, 6 Oct 2016 22:46:31 +0100 Subject: [PATCH] Popular function respects track limit --- app/Models/Track.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Models/Track.php b/app/Models/Track.php index d483300d..30c8c3fe 100644 --- a/app/Models/Track.php +++ b/app/Models/Track.php @@ -341,7 +341,7 @@ class Track extends Model implements Searchable, Commentable, Favouritable '.$explicitFilter.' GROUP BY track_id ORDER BY weight DESC - LIMIT 30;'; + LIMIT '.$count; $countQuery = DB::select(DB::raw($queryText));