Skip to content

Commit

Permalink
Add adapter artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
KaptenJansson committed Nov 16, 2017
1 parent cce01ad commit 527cbaf
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
3 changes: 2 additions & 1 deletion release/adapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -3777,10 +3777,11 @@ var firefoxShim = {
return;
}
window.RTCPeerConnection.prototype.removeStream = function(stream) {
var pc = this;
utils.deprecated('removeStream', 'removeTrack');
this.getSenders().forEach(function(sender) {
if (sender.track && stream.getTracks().indexOf(sender.track) !== -1) {
this.removeTrack(sender);
pc.removeTrack(sender);
}
});
};
Expand Down
3 changes: 2 additions & 1 deletion release/adapter_no_edge.js
Original file line number Diff line number Diff line change
Expand Up @@ -2101,10 +2101,11 @@ var firefoxShim = {
return;
}
window.RTCPeerConnection.prototype.removeStream = function(stream) {
var pc = this;
utils.deprecated('removeStream', 'removeTrack');
this.getSenders().forEach(function(sender) {
if (sender.track && stream.getTracks().indexOf(sender.track) !== -1) {
this.removeTrack(sender);
pc.removeTrack(sender);
}
});
};
Expand Down
3 changes: 2 additions & 1 deletion release/adapter_no_edge_no_global.js
Original file line number Diff line number Diff line change
Expand Up @@ -2101,10 +2101,11 @@ var firefoxShim = {
return;
}
window.RTCPeerConnection.prototype.removeStream = function(stream) {
var pc = this;
utils.deprecated('removeStream', 'removeTrack');
this.getSenders().forEach(function(sender) {
if (sender.track && stream.getTracks().indexOf(sender.track) !== -1) {
this.removeTrack(sender);
pc.removeTrack(sender);
}
});
};
Expand Down
3 changes: 2 additions & 1 deletion release/adapter_no_global.js
Original file line number Diff line number Diff line change
Expand Up @@ -3777,10 +3777,11 @@ var firefoxShim = {
return;
}
window.RTCPeerConnection.prototype.removeStream = function(stream) {
var pc = this;
utils.deprecated('removeStream', 'removeTrack');
this.getSenders().forEach(function(sender) {
if (sender.track && stream.getTracks().indexOf(sender.track) !== -1) {
this.removeTrack(sender);
pc.removeTrack(sender);
}
});
};
Expand Down

0 comments on commit 527cbaf

Please sign in to comment.