From defaf990eca6218d80612980314634decf644656 Mon Sep 17 00:00:00 2001 From: nanaya Date: Tue, 10 Dec 2024 21:53:50 +0900 Subject: [PATCH] Notify all users on beatmap owner change --- app/Jobs/Notifications/BeatmapOwnerChange.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/Jobs/Notifications/BeatmapOwnerChange.php b/app/Jobs/Notifications/BeatmapOwnerChange.php index c72d025e01a..7bd13d744b9 100644 --- a/app/Jobs/Notifications/BeatmapOwnerChange.php +++ b/app/Jobs/Notifications/BeatmapOwnerChange.php @@ -15,7 +15,6 @@ class BeatmapOwnerChange extends BroadcastNotificationBase protected $beatmap; protected $beatmapset; - protected $user; public static function getMailLink(Notification $notification): string { @@ -32,7 +31,6 @@ public function __construct(Beatmap $beatmap, User $source) $this->beatmap = $beatmap; $this->beatmapset = $beatmap->beatmapset; - $this->user = $beatmap->user; } public function getDetails(): array @@ -48,7 +46,7 @@ public function getDetails(): array public function getListeningUserIds(): array { - return [$this->user->getKey()]; + return $this->beatmap->beatmapOwners()->pluck('user_id')->all(); } public function getNotifiable()