Fixed unclean DownTrack close when removed before bound. (#736)
* Fixed unclean DownTrack close when removed before bound. When a DownTrack is closed before it had a chance to be bound to a transceiver, we'd skip close and leave it hanging. This is unlikely in normal operations. However, it can be seen with permissions and subscription APIs. * remove remaining peerID references
This commit is contained in:
@@ -38,7 +38,8 @@ func HandleParticipantSignal(room types.Room, participant types.LocalParticipant
|
||||
participant.SetTrackMuted(livekit.TrackID(msg.Mute.Sid), msg.Mute.Muted, false)
|
||||
case *livekit.SignalRequest_Subscription:
|
||||
var err error
|
||||
if participant.CanSubscribe() {
|
||||
// always allow unsubscribe
|
||||
if participant.CanSubscribe() || !msg.Subscription.Subscribe {
|
||||
updateErr := room.UpdateSubscriptions(
|
||||
participant,
|
||||
livekit.StringsAsTrackIDs(msg.Subscription.TrackSids),
|
||||
|
||||
Reference in New Issue
Block a user