Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/spreed.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-10-23 14:26:52 +0300
committerJoas Schilling <coding@schilljs.com>2020-10-30 12:38:49 +0300
commitad6a3ae7cb8a244ca70f62ccaef7247cdbb348f0 (patch)
tree779b72d08706599e5a1778b57707612a81abc560 /lib/Room.php
parent204d80fe29e8e8216344f4f9818e4f63ce9a0d21 (diff)
Move changeInCall to particiant service
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/Room.php')
-rw-r--r--lib/Room.php29
1 files changed, 0 insertions, 29 deletions
diff --git a/lib/Room.php b/lib/Room.php
index e33f20ff4..bdeece6b6 100644
--- a/lib/Room.php
+++ b/lib/Room.php
@@ -855,35 +855,6 @@ class Room {
$this->dispatcher->dispatch(self::EVENT_AFTER_ROOM_DISCONNECT, $event);
}
- public function changeInCall(Participant $participant, int $flags): void {
- $event = new ModifyParticipantEvent($this, $participant, 'inCall', $flags, $participant->getInCallFlags());
- if ($flags !== Participant::FLAG_DISCONNECTED) {
- $this->dispatcher->dispatch(self::EVENT_BEFORE_SESSION_JOIN_CALL, $event);
- } else {
- $this->dispatcher->dispatch(self::EVENT_BEFORE_SESSION_LEAVE_CALL, $event);
- }
-
- $query = $this->db->getQueryBuilder();
- $query->update('talk_participants')
- ->set('in_call', $query->createNamedParameter($flags, IQueryBuilder::PARAM_INT))
- ->where($query->expr()->eq('session_id', $query->createNamedParameter($participant->getSessionId())))
- ->andWhere($query->expr()->eq('room_id', $query->createNamedParameter($this->getId(), IQueryBuilder::PARAM_INT)));
-
- if ($flags !== Participant::FLAG_DISCONNECTED) {
- $query->set('last_joined_call', $query->createNamedParameter(
- $this->timeFactory->getDateTime(), IQueryBuilder::PARAM_DATE
- ));
- }
-
- $query->execute();
-
- if ($flags !== Participant::FLAG_DISCONNECTED) {
- $this->dispatcher->dispatch(self::EVENT_AFTER_SESSION_JOIN_CALL, $event);
- } else {
- $this->dispatcher->dispatch(self::EVENT_AFTER_SESSION_LEAVE_CALL, $event);
- }
- }
-
/**
* @param string $password
* @return array