Skip to content

Commit 084ee9c

Browse files
author
Igor Khomenko
committed
Merge pull request #81 from fc/gh-pages
Throw an exception when the element is undefined
2 parents 35e818b + e44314d commit 084ee9c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

js/modules/qbWebRTC.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,8 @@ WebRTCProxy.prototype.attachMediaStream = function(id, stream, options) {
297297
elem.style.transform = 'scaleX(-1)';
298298
}
299299
elem.play();
300+
} else {
301+
throw new Error('Unable to attach media stream, element ' + elemId + ' is undefined');
300302
}
301303
};
302304

0 commit comments

Comments
 (0)