collection->map( fn (Announcement $announcement): AnnouncementJsonResource => new AnnouncementJsonResource($announcement, $this->query) )->all(); } }