Fix FS-11874

Verto JS libs allow passing an attachStreams array of MediaStream objects, which are then supposed to be added to the peer connection in the order they are supplied in the array.

However, there is a faulty logic check prior to actually adding the streams, where 'options.attachStream' is checked for length instead of 'options.attachStreams'.
This commit is contained in:
Chad Phillips 2019-05-31 11:07:11 -07:00
parent ed135a21d5
commit 8fdc4433e5
1 changed files with 1 additions and 1 deletions

View File

@ -778,7 +778,7 @@
// attachStreams[0] = audio-stream;
// attachStreams[1] = video-stream;
// attachStreams[2] = screen-capturing-stream;
if (options.attachStreams && options.attachStream.length) {
if (options.attachStreams && options.attachStreams.length) {
var streams = options.attachStreams;
for (var i = 0; i < streams.length; i++) {
peer.addStream(streams[i]);