From fd32fd83583c902bec236c282a3a0ec00382421e Mon Sep 17 00:00:00 2001 From: Mohammed Raihan <51045712+RaihanIIUC@users.noreply.github.com> Date: Wed, 28 May 2025 11:26:13 +0600 Subject: [PATCH] Update InteractsWithViews.php Signed-off-by: Mohammed Raihan <51045712+RaihanIIUC@users.noreply.github.com> --- src/InteractsWithViews.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/InteractsWithViews.php b/src/InteractsWithViews.php index 232d045..e8f53e6 100644 --- a/src/InteractsWithViews.php +++ b/src/InteractsWithViews.php @@ -50,7 +50,7 @@ public function scopeOrderByViews( string $as = 'views_count' ): Builder { return $query->withViewsCount($period, $collection, $unique, $as) - ->orderBy($as, $direction); + ->orderBy('id', $direction); } /**