Reset DD tracker layers when muted. (#2920)

* Reset DD tracker layers when muted.

@cnderrauber, I think this is okay to do, but please let me know if
there are gotchas in there.

* copy

* more compact form
This commit is contained in:
Raja Subramanian
2024-08-10 15:42:14 +05:30
committed by GitHub
parent 64057c3e4d
commit d0ac19779e
2 changed files with 15 additions and 3 deletions
+1 -3
View File
@@ -545,9 +545,7 @@ func (s *StreamAllocator) maybePostEventAllocateTrack(downTrack *sfu.DownTrack)
shouldPost := false
s.videoTracksMu.Lock()
if track := s.videoTracks[livekit.TrackID(downTrack.ID())]; track != nil {
if track.SetDirty(true) {
shouldPost = true
}
shouldPost = track.SetDirty(true)
}
s.videoTracksMu.Unlock()