with(['following', 'followers']) ->firstOrFail(); $mods = $user->mods() ->with([ 'users', 'latestVersion', 'latestVersion.latestSptVersion', ]) ->orderByDesc('created_at') ->paginate(10) ->fragment('mods'); if ($user->slug() !== $username) { abort(404); } if ($request->user()?->cannot('view', $user)) { abort(403); } return view('user.show', compact('user', 'mods')); } }