fixed panic when client connected abruptly
This commit is contained in:
+2
-2
@@ -194,8 +194,8 @@ func (r *Room) broadcastParticipantState(p types.Participant) {
|
||||
|
||||
updates := ToProtoParticipants([]types.Participant{p})
|
||||
for _, op := range r.participants {
|
||||
// skip itself
|
||||
if p.ID() == op.ID() {
|
||||
// skip itself && closed participants
|
||||
if p.ID() == op.ID() || p.State() == livekit.ParticipantInfo_DISCONNECTED {
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user