Fix TypeError when one of audioTracks or videoTracks was undefined

This commit is contained in:
tsareg 2016-06-09 12:38:30 +03:00
parent 61fa2d8ed1
commit f72e3bf552
1 changed files with 2 additions and 1 deletions

View File

@ -594,7 +594,8 @@ export default {
videoTrackCreationError);
}
return audioTracks.concat(videoTracks);
return (audioTracks || [])
.concat(videoTracks || []);
});
} else {
promise = createAudioTrack();