diff options
author | Joas Schilling <213943+nickvergessen@users.noreply.github.com> | 2024-04-29 11:46:32 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-29 11:46:32 +0200 |
commit | a6aa9f6c6225670cee278e4cc9cdd685a745ab4b (patch) | |
tree | 1f6ecd88e0febda18cdbb268c4c551b8f7bead19 | |
parent | 2a43ff79ab00c16dc30279b1c2e85109ae5cc41a (diff) | |
parent | 14b4c4477caefaa38076ef2a17d206b62138a54b (diff) |
Merge pull request #12198 from nextcloud/bugfix/noid/make-alluserids-more-reliable
fix(signaling): Make alluserids more reliable for testing
-rw-r--r-- | lib/Signaling/BackendNotifier.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/Signaling/BackendNotifier.php b/lib/Signaling/BackendNotifier.php index 8cf54e2c6..38719bf76 100644 --- a/lib/Signaling/BackendNotifier.php +++ b/lib/Signaling/BackendNotifier.php @@ -176,6 +176,8 @@ class BackendNotifier { * @throws \Exception */ public function roomsDisinvited(Room $room, array $attendees): void { + $allUserIds = $this->participantService->getParticipantUserIds($room); + sort($allUserIds); $userIds = []; foreach ($attendees as $attendee) { if ($attendee->getActorType() === Attendee::ACTOR_USERS) { @@ -189,7 +191,7 @@ class BackendNotifier { 'userids' => $userIds, // TODO(fancycode): We should try to get rid of 'alluserids' and // find a better way to notify existing users to update the room. - 'alluserids' => $this->participantService->getParticipantUserIds($room), + 'alluserids' => $allUserIds, 'properties' => $room->getPropertiesForSignaling('', false), ], ]); @@ -210,6 +212,8 @@ class BackendNotifier { * @throws \Exception */ public function roomSessionsRemoved(Room $room, array $sessionIds): void { + $allUserIds = $this->participantService->getParticipantUserIds($room); + sort($allUserIds); $start = microtime(true); $this->backendRequest($room, [ 'type' => 'disinvite', @@ -217,7 +221,7 @@ class BackendNotifier { 'sessionids' => $sessionIds, // TODO(fancycode): We should try to get rid of 'alluserids' and // find a better way to notify existing users to update the room. - 'alluserids' => $this->participantService->getParticipantUserIds($room), + 'alluserids' => $allUserIds, 'properties' => $room->getPropertiesForSignaling('', false), ], ]); |