diff options
author | Joas Schilling <213943+nickvergessen@users.noreply.github.com> | 2023-05-02 22:01:51 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-02 22:01:51 +0200 |
commit | c4fee5eec162fc146c9000f171ea4d4273fc70de (patch) | |
tree | 67e21c45ef8ec7c06f0af439a666c9b69261813f /lib/Controller/RoomController.php | |
parent | e1bb98efcd1017bcc7b9b8cdef5386cfd38e2be7 (diff) | |
parent | 0cf8800f20bc8a7b3c6368288a3d622bbf5c0d28 (diff) |
Merge pull request #9412 from nextcloud/bugfix/8787/keep-guest-attendees-with-values
Bugfix/8787/keep guest attendees with values
Diffstat (limited to 'lib/Controller/RoomController.php')
-rw-r--r-- | lib/Controller/RoomController.php | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/lib/Controller/RoomController.php b/lib/Controller/RoomController.php index 787a2d63d..920624aa6 100644 --- a/lib/Controller/RoomController.php +++ b/lib/Controller/RoomController.php @@ -829,9 +829,18 @@ class RoomController extends AEnvironmentAwareController { $result['statusClearAt'] = null; } } elseif ($participant->getAttendee()->getActorType() === Attendee::ACTOR_GUESTS) { - if ($result['lastPing'] <= $maxPingAge) { - $cleanGuests = true; - continue; + if ($participant->getAttendee()->getParticipantType() === Participant::GUEST + && ($participant->getAttendee()->getPermissions() === Attendee::PERMISSIONS_DEFAULT + || $participant->getAttendee()->getPermissions() === Attendee::PERMISSIONS_CUSTOM)) { + // Guests without an up-to-date session are filtered out. We + // only keep there attendees in the database, so that the + // comments show the display name. Only when they have + // non-default permissions we show them, so permissions can + // be reset or removed + if ($result['lastPing'] <= $maxPingAge) { + $cleanGuests = true; + continue; + } } $result['displayName'] = $participant->getAttendee()->getDisplayName(); |