fix: eager loading regression from #2908

- category was duplicated awhile back in https://github.com/HDInnovations/UNIT3D-Community-Edition/pull/2908
This commit is contained in:
HDVinnie
2024-12-03 23:03:48 -05:00
parent e71b28c588
commit 193c280358

View File

@@ -48,15 +48,15 @@ class ModerationController extends Controller
return view('Staff.moderation.index', [
'current' => now(),
'pending' => Torrent::withoutGlobalScope(ApprovedScope::class)
->with(['user.group', 'category', 'type', 'resolution', 'category'])
->with(['user.group', 'category', 'type', 'resolution'])
->where('status', '=', Torrent::PENDING)
->get(),
'postponed' => Torrent::withoutGlobalScope(ApprovedScope::class)
->with(['user.group', 'moderated.group', 'category', 'type', 'resolution', 'category'])
->with(['user.group', 'moderated.group', 'category', 'type', 'resolution'])
->where('status', '=', Torrent::POSTPONED)
->get(),
'rejected' => Torrent::withoutGlobalScope(ApprovedScope::class)
->with(['user.group', 'moderated.group', 'category', 'type', 'resolution', 'category'])
->with(['user.group', 'moderated.group', 'category', 'type', 'resolution'])
->where('status', '=', Torrent::REJECTED)
->get(),
]);