diff options
author | Joas Schilling <coding@schilljs.com> | 2020-11-17 22:59:03 +0300 |
---|---|---|
committer | Joas Schilling <coding@schilljs.com> | 2020-11-26 16:32:26 +0300 |
commit | a655825bff8bc882106e3ebb80b750b65fd6d01d (patch) | |
tree | 37efa5d4d3a93b264ffa6b55d5cc5b45911712e1 /lib | |
parent | df69c33e4b60a9c10e7210c92ec137e0fe37e989 (diff) |
Simplify getting the participant
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Controller/SignalingController.php | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/lib/Controller/SignalingController.php b/lib/Controller/SignalingController.php index adf4375d4..9902e27de 100644 --- a/lib/Controller/SignalingController.php +++ b/lib/Controller/SignalingController.php @@ -543,17 +543,16 @@ class SignalingController extends OCSController { ]); } - try { - if ($sessionId) { - try { - $participant = $room->getParticipantBySession($sessionId); - } catch (ParticipantNotFoundException $e) { - $participant = $room->getParticipantByActor($actorType, $actorId); - } - } else { + if ($sessionId) { + try { + $participant = $room->getParticipantBySession($sessionId); + } catch (ParticipantNotFoundException $e) { + } + } else { + try { $participant = $room->getParticipantByActor($actorType, $actorId); + } catch (ParticipantNotFoundException $e) { } - } catch (ParticipantNotFoundException $e) { } } else { try { |