diff options
author | Joas Schilling <coding@schilljs.com> | 2021-01-21 12:58:06 +0300 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2021-01-21 12:58:06 +0300 |
commit | d34fb518a1cdff943cd675f68e1d99d8dc437258 (patch) | |
tree | 6019d6fc8392a04164faf12b12e7a19dd8db457f /lib/Collaboration/Resources/Listener.php | |
parent | 93fcd525ecd7c93aa640613d4449bcff7c5fb678 (diff) |
Fix "Undefined index: userId"
Regression from the participant rewrite
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Collaboration/Resources/Listener.php')
-rw-r--r-- | lib/Collaboration/Resources/Listener.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/Collaboration/Resources/Listener.php b/lib/Collaboration/Resources/Listener.php index 57f8be678..35aeb511c 100644 --- a/lib/Collaboration/Resources/Listener.php +++ b/lib/Collaboration/Resources/Listener.php @@ -28,6 +28,7 @@ use OCA\Talk\Events\RemoveParticipantEvent; use OCA\Talk\Events\RemoveUserEvent; use OCA\Talk\Events\RoomEvent; use OCA\Talk\GuestManager; +use OCA\Talk\Model\Attendee; use OCA\Talk\Room; use OCP\Collaboration\Resources\IManager; use OCP\Collaboration\Resources\ResourceException; @@ -65,8 +66,8 @@ class Listener { $participants = $event->getParticipants(); foreach ($participants as $participant) { $user = null; - if ($participant['userId'] !== '') { - $user = $userManager->get($participant['userId']); + if ($participant['actorType'] === Attendee::ACTOR_USERS) { + $user = $userManager->get($participant['actorId']); } $resourceManager->invalidateAccessCacheForResourceByUser($resource, $user); |