[mirotalksfu] - WIP lobby
هذا الالتزام موجود في:
@@ -107,6 +107,7 @@ module.exports = class Room {
|
||||
shareMediaData: this.shareMediaData,
|
||||
dominantSpeaker: this.activeSpeakerObserverEnabled,
|
||||
peers: JSON.stringify([...this.peers]),
|
||||
peersCount: this.getPeersCount(),
|
||||
maxParticipants: this.maxParticipants,
|
||||
maxParticipantsReached: this.peers.size > this.maxParticipants,
|
||||
globalLobby: this.globalLobby,
|
||||
|
||||
@@ -1923,7 +1923,7 @@ function startServer() {
|
||||
return cb('isLocked');
|
||||
}
|
||||
|
||||
if (room.isLobbyEnabled() && !isPresenter) {
|
||||
if ((room.isLobbyEnabled() || room.isGlobalLobbyEnabled()) && !isPresenter) {
|
||||
log.debug(
|
||||
'The user is currently waiting to join the room because the lobby is enabled, and they are not a presenter'
|
||||
);
|
||||
@@ -1935,11 +1935,6 @@ function startServer() {
|
||||
return cb('isLobby');
|
||||
}
|
||||
|
||||
if (room.isGlobalLobbyEnabled() && !isPresenter) {
|
||||
log.debug('The user is currently waiting to join the room because the global lobby is enabled');
|
||||
return cb('isGlobalLobby');
|
||||
}
|
||||
|
||||
if ((hostCfg.protected || hostCfg.user_auth) && isPresenter && !hostCfg.users_from_db) {
|
||||
const roomAllowedForUser = isRoomAllowedForUser('[Join]', peer_name, room.id);
|
||||
if (!roomAllowedForUser) {
|
||||
@@ -2409,6 +2404,10 @@ function startServer() {
|
||||
room.setLocked(false);
|
||||
room.broadCast(socket.id, 'roomAction', data.action);
|
||||
break;
|
||||
case 'globalLobbyOn':
|
||||
if (!room.isGlobalLobbyEnabled()) return;
|
||||
room.setLobbyEnabled(true);
|
||||
break;
|
||||
case 'lobbyOn':
|
||||
if (!isPresenter) return;
|
||||
room.setLobbyEnabled(true);
|
||||
|
||||
المرجع في مشكلة جديدة
حظر مستخدم