mirror of
https://github.com/livekit/livekit.git
synced 2026-10-22 15:22:30 +00:00
fixed logic error in speaker updates
This commit is contained in:
1 parent
f0d8b1c7ee
commit
bc8becaff6
1 file changed
+1
-1
+1
-1
@@ -538,7 +538,7 @@ func (r *Room) audioUpdateWorker() {
|
||||
}
|
||||
|
||||
// see if an update is needed
|
||||
if len(speakers) == 0 && len(r.lastActiveSpeakers) == 0 {
|
||||
if len(speakers) == len(r.lastActiveSpeakers) {
|
||||
for i, speaker := range speakers {
|
||||
if speaker.Sid != r.lastActiveSpeakers[i].Sid || speaker.Level != r.lastActiveSpeakers[i].Level {
|
||||
r.sendSpeakerUpdates(speakers)
|
||||
|
||||
Reference in new issue
Block a user