Skip to content

Commit

Permalink
fix(conversation): Only trigger event with users that really got removed
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <coding@schilljs.com>
  • Loading branch information
nickvergessen authored and backportbot[bot] committed Feb 14, 2025
1 parent 6b085e9 commit 02d5b5b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Service/ParticipantService.php
Original file line number Diff line number Diff line change
Expand Up @@ -1007,10 +1007,10 @@ public function removeGroupMembers(Room $room, Participant $removedGroupParticip
$participant = $this->getParticipant($room, $user->getUID());
$participantType = $participant->getAttendee()->getParticipantType();

$attendees[] = $participant->getAttendee();
if ($participantType === Participant::USER) {
// Only remove normal users, not moderators/admins
$this->removeAttendee($room, $participant, $reason, true);
$attendees[] = $participant->getAttendee();
}
} catch (ParticipantNotFoundException $e) {
}
Expand Down Expand Up @@ -1070,10 +1070,10 @@ public function removeCircleMembers(Room $room, Participant $removedCirclePartic
$participant = $this->getParticipant($room, $user->getUID());
$participantType = $participant->getAttendee()->getParticipantType();

$attendees[] = $participant->getAttendee();
if ($participantType === Participant::USER) {
// Only remove normal users, not moderators/admins
$this->removeAttendee($room, $participant, $reason, true);
$attendees[] = $participant->getAttendee();
}
} catch (ParticipantNotFoundException $e) {
}
Expand Down

0 comments on commit 02d5b5b

Please sign in to comment.