Skip to content

Commit

Permalink
doc(TraceablePeerConnection): comment on warning msg
Browse files Browse the repository at this point in the history
  • Loading branch information
paweldomas committed Feb 27, 2017
1 parent bed6c84 commit 7c9519a
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions modules/RTC/TraceablePeerConnection.js
Original file line number Diff line number Diff line change
Expand Up @@ -382,10 +382,19 @@ TraceablePeerConnection.prototype._remoteTrackRemoved
}

if (!this.rtc._removeRemoteTrack(streamId, trackId)) {
GlobalOnErrorHandler.callErrorHandler(
new Error(
"Removed track not found for msid: " + streamId
+ "track id: " + trackId));
// NOTE this warning is always printed when user leaves the room,
// because we remove remote tracks manually on MUC member left event,
// before the SSRCs are removed by Jicofo. In most cases it is fine to
// ignore this warning, but still it's better to keep it printed for
// debugging purposes.
//
// We could change the behaviour to emit track removed only from here,
// but the order of the events will change and consuming apps could
// behave unexpectedly (the "user left" event would come before "track
// removed" events).
logger.warn(
"Removed track not found for msid: " + streamId
+ "track id: " + trackId);
}
};

Expand Down

0 comments on commit 7c9519a

Please sign in to comment.