public function activities(Domain $domain, Blog $id, SearchUserActivity $request): JsonResource 	{ 		$type = $request->type;  		return UserActivityResource::collection($id->activities() 			->includes() 			->available() 			->when($type, function (object $query) use ($type): void { 				$query->where('type', $type); 			}) 			->search($request->search) 			->latest() 			->paginate() 			->withQueryString()); 	}