When switching public rooms disconnect from devices in old room (fixes #298)

This commit is contained in:
schlagmichdoch 2024-05-16 19:44:43 +02:00
parent 9b3571feac
commit be381ea438
3 changed files with 24 additions and 18 deletions

View file

@ -251,7 +251,6 @@ export default class PairDropWsServer {
return;
}
this._leavePublicRoom(sender);
this._joinPublicRoom(sender, message.publicRoomId);
}
@ -312,7 +311,7 @@ export default class PairDropWsServer {
_joinPublicRoom(peer, publicRoomId) {
// prevent joining of 2 public rooms simultaneously
this._leavePublicRoom(peer);
this._leavePublicRoom(peer, true);
this._joinRoom(peer, 'public-id', publicRoomId);