Skip to content

Commit

Permalink
Merge pull request #11737 from nanaya/owner-change-notification-user-ids
Browse files Browse the repository at this point in the history
Notify all owners on beatmap owner change
  • Loading branch information
notbakaneko authored Dec 11, 2024
2 parents 642e973 + 59c0349 commit 832f2bb
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions app/Jobs/Notifications/BeatmapOwnerChange.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ class BeatmapOwnerChange extends BroadcastNotificationBase

protected $beatmap;
protected $beatmapset;
protected $user;

public static function getMailLink(Notification $notification): string
{
Expand All @@ -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
Expand All @@ -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()
Expand Down

0 comments on commit 832f2bb

Please sign in to comment.