mirror of
https://github.com/nextcloud/spreed.git
synced 2025-12-17 21:12:20 +01:00
feat(userstatus): use busy status for calls
Signed-off-by: Anna Larch <anna@nextcloud.com>
This commit is contained in:
parent
bbf871bb1c
commit
4773851fd3
2 changed files with 6 additions and 3 deletions
|
|
@ -62,7 +62,7 @@ class Listener implements IEventListener {
|
|||
|
||||
protected function setUserStatus(BeforeParticipantModifiedEvent $event): void {
|
||||
|
||||
$status = IUserStatus::AWAY;
|
||||
$status = IUserStatus::BUSY;
|
||||
|
||||
$userId = $event->getParticipant()->getAttendee()->getActorId();
|
||||
|
||||
|
|
@ -90,13 +90,13 @@ class Listener implements IEventListener {
|
|||
}
|
||||
|
||||
protected function revertUserStatusOnLeaveCall(BeforeParticipantModifiedEvent $event): void {
|
||||
$this->statusManager->revertUserStatus($event->getParticipant()->getAttendee()->getActorId(), 'call', IUserStatus::AWAY);
|
||||
$this->statusManager->revertUserStatus($event->getParticipant()->getAttendee()->getActorId(), 'call', IUserStatus::BUSY);
|
||||
}
|
||||
|
||||
protected function revertUserStatusOnEndCallForEveryone(CallEndedForEveryoneEvent $event): void {
|
||||
$userIds = $event->getUserIds();
|
||||
if (!empty($userIds)) {
|
||||
$this->statusManager->revertMultipleUserStatus($userIds, 'call', IUserStatus::AWAY);
|
||||
$this->statusManager->revertMultipleUserStatus($userIds, 'call', IUserStatus::BUSY);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -87,3 +87,6 @@ Feature: chat/one-to-one
|
|||
Then user "participant2" set status to "away" with 200 (v1)
|
||||
Then user "participant1" gets room "one-to-one room" with 200 (v4)
|
||||
| status | away |
|
||||
Then user "participant2" set status to "busy" with 200 (v1)
|
||||
Then user "participant1" gets room "one-to-one room" with 200 (v4)
|
||||
| status | busy |
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue