Skip to content

Commit

Permalink
Drop guest moderators when changing a conversation to group conversation
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <coding@schilljs.com>
  • Loading branch information
nickvergessen committed Feb 19, 2021
1 parent 43e85f5 commit 77fb711
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Room.php
Original file line number Diff line number Diff line change
Expand Up @@ -792,7 +792,7 @@ public function setType(int $newType): bool {
$query = $this->db->getQueryBuilder();
$query->delete('talk_attendees')
->where($query->expr()->eq('room_id', $query->createNamedParameter($this->getId(), IQueryBuilder::PARAM_INT)))
->andWhere($query->expr()->in('participant_type', $query->createNamedParameter([Participant::GUEST, Participant::USER_SELF_JOINED], IQueryBuilder::PARAM_INT_ARRAY)));
->andWhere($query->expr()->in('participant_type', $query->createNamedParameter([Participant::GUEST, Participant::GUEST_MODERATOR, Participant::USER_SELF_JOINED], IQueryBuilder::PARAM_INT_ARRAY)));
$query->execute();
}

Expand Down

0 comments on commit 77fb711

Please sign in to comment.