Change to total number of peers, not just joined. Styling.
parent
e2421f094f
commit
7adcef19a3
|
|
@ -218,7 +218,12 @@ class Room extends EventEmitter
|
|||
peer.roles.some((role) => accessFromRoles.BYPASS_ROOM_LOCK.includes(role))
|
||||
)
|
||||
this._peerJoining(peer);
|
||||
else if ('maxUsersPerRoom' in config &&(this._getJoinedPeers().length + this._lobby.peerList().length) >= config.maxUsersPerRoom)
|
||||
else if (
|
||||
'maxUsersPerRoom' in config &&
|
||||
(
|
||||
Object.keys(this._peers).length +
|
||||
this._lobby.peerList().length
|
||||
) >= config.maxUsersPerRoom)
|
||||
{
|
||||
this._handleOverRoomLimit(peer);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue