Skip to content

Commit 607f06b

Browse files
committed
fix: include deleted torrents in top nav torrent downloads
This value in the top nav wasn't matching the value on the profile. The downloads number should be all time, and not only count existing torrents.
1 parent 9226538 commit 607f06b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/View/Composers/TopNavComposer.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ public function compose(View $view): void
9393
'downloadCount' => cache()->remember(
9494
"users:{$user->id}:download-count",
9595
60,
96-
fn () => $user->history()->where('actual_downloaded', '>', 0)->count(),
96+
fn () => $user->history()->withoutGlobalScopes()->where('actual_downloaded', '>', 0)->count(),
9797
),
9898
'user' => $user,
9999
]);

0 commit comments

Comments
 (0)