Преглед изворни кода

Fixes this reference in removeStream method.

dev1
damencho пре 10 година
родитељ
комит
f4eb4450d5
1 измењених фајлова са 2 додато и 2 уклоњено
  1. 2
    2
      modules/xmpp/JingleSessionPC.js

+ 2
- 2
modules/xmpp/JingleSessionPC.js Прегледај датотеку

@@ -1112,7 +1112,7 @@ JingleSessionPC.prototype.removeStream = function (stream, callback, ssrcInfo) {
1112 1112
             }
1113 1113
 
1114 1114
             // Find the right sender (for audio or video)
1115
-            self.peerconnection.peerconnection.getSenders().some(function (s) {
1115
+            this.peerconnection.peerconnection.getSenders().some(function (s) {
1116 1116
                 if (s.track === track) {
1117 1117
                     sender = s;
1118 1118
                     return true;
@@ -1120,7 +1120,7 @@ JingleSessionPC.prototype.removeStream = function (stream, callback, ssrcInfo) {
1120 1120
             });
1121 1121
 
1122 1122
             if (sender) {
1123
-                self.peerconnection.peerconnection.removeTrack(sender);
1123
+                this.peerconnection.peerconnection.removeTrack(sender);
1124 1124
             } else {
1125 1125
                 logger.log("Cannot remove tracks: no RTPSender.");
1126 1126
             }

Loading…
Откажи
Сачувај