summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rw-r--r--js/lib/janus.js4
-rw-r--r--js/lib/janus.nojquery.js4
2 files changed, 4 insertions, 4 deletions
diff --git a/js/lib/janus.js b/js/lib/janus.js
index b8bc4f3..c9e1118 100644
--- a/js/lib/janus.js
+++ b/js/lib/janus.js
@@ -1294,11 +1294,11 @@ function Janus(gatewayCallbacks) {
config.pc.addStream(stream);
pluginHandle.onlocalstream(stream);
}
- config.pc.ontrack = function(remoteStream) {
+ config.pc.onaddstream = function(remoteStream) {
Janus.log("Handling Remote Stream");
Janus.debug(remoteStream);
config.remoteStream = remoteStream;
- pluginHandle.onremotestream(remoteStream.streams[0]);
+ pluginHandle.onremotestream(remoteStream.stream);
};
// Any data channel to create?
if(isDataEnabled(media)) {
diff --git a/js/lib/janus.nojquery.js b/js/lib/janus.nojquery.js
index 2343ac6..235ff55 100644
--- a/js/lib/janus.nojquery.js
+++ b/js/lib/janus.nojquery.js
@@ -1346,11 +1346,11 @@ function Janus(gatewayCallbacks) {
config.pc.addStream(stream);
pluginHandle.onlocalstream(stream);
}
- config.pc.ontrack = function(remoteStream) {
+ config.pc.onaddstream = function(remoteStream) {
Janus.log("Handling Remote Stream");
Janus.debug(remoteStream);
config.remoteStream = remoteStream;
- pluginHandle.onremotestream(remoteStream.streams[0]);
+ pluginHandle.onremotestream(remoteStream.stream);
};
// Any data channel to create?
if(isDataEnabled(media)) {