diff options
author | Joas Schilling <coding@schilljs.com> | 2020-10-27 17:31:32 +0300 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2020-10-30 12:38:51 +0300 |
commit | d24e52326931bf60fca1030185732817572735f9 (patch) | |
tree | f9152f803c7886302f7688187eff8ad3bcb58d6a /lib/Signaling/BackendNotifier.php | |
parent | 164da758eef468523506b031c04a665dc7c3a084 (diff) |
Fix the unit tests
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Signaling/BackendNotifier.php')
-rw-r--r-- | lib/Signaling/BackendNotifier.php | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/Signaling/BackendNotifier.php b/lib/Signaling/BackendNotifier.php index 19bb07899..caa74e72e 100644 --- a/lib/Signaling/BackendNotifier.php +++ b/lib/Signaling/BackendNotifier.php @@ -147,7 +147,9 @@ class BackendNotifier { $this->logger->info('Now invited to ' . $room->getToken() . ': ' . print_r($users, true)); $userIds = []; foreach ($users as $user) { - $userIds[] = $user['userId']; + if ($user['actorType'] === 'users') { + $userIds[] = $user['actorId']; + } } $this->backendRequest($room, [ 'type' => 'invite', @@ -262,10 +264,9 @@ class BackendNotifier { 'sessionId' => '0', 'participantType' => $attendee->getParticipantType(), ]; - if ($attendee->getActorType() !== 'users') { + if ($attendee->getActorType() === 'users') { $data['userId'] = $attendee->getActorId(); } - $users[] = $data; $session = $participant->getSession(); if ($session instanceof Session) { @@ -323,7 +324,7 @@ class BackendNotifier { 'sessionId' => '0', 'participantType' => $attendee->getParticipantType(), ]; - if ($attendee->getActorType() !== 'users') { + if ($attendee->getActorType() === 'users') { $data['userId'] = $attendee->getActorId(); } |