Update webrtc.js

The above change corrects at least firefox RTC Peer handler where it **throws** on over 6 ice servers, and updates url: to urls: removing spec deprecation warnings

Left todo: when ICE Fails it throws, and all `.on` and `.open` listeners will fail
This commit is contained in:
Jabis Sevon 2020-01-31 03:32:56 +07:00 committed by GitHub
parent 9dbbf856d3
commit b3f87b180e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -21,13 +21,16 @@
opt.RTCSessionDescription = rtcsd;
opt.RTCIceCandidate = rtcic;
opt.rtc = opt.rtc || {'iceServers': [
{url: 'stun:stun.l.google.com:19302'},
{url: "stun:stun.sipgate.net:3478"},
{url: "stun:stun.stunprotocol.org"},
{url: "stun:stun.sipgate.net:10000"},
{url: "stun:217.10.68.152:10000"},
{url: 'stun:stun.services.mozilla.com'}
{urls: 'stun:stun.l.google.com:19302'},
{urls: "stun:stun.sipgate.net:3478"}/*,
{urls: "stun:stun.stunprotocol.org"},
{urls: "stun:stun.sipgate.net:10000"},
{urls: "stun:217.10.68.152:10000"},
{urls: 'stun:stun.services.mozilla.com'}*/
]};
// TODO: Select the most appropriate stuns.
// FIXME: Find the wire throwing ICE Failed
// The above change corrects at least firefox RTC Peer handler where it **throws** on over 6 ice servers, and updates url: to urls: removing deprecation warning
opt.rtc.dataChannel = opt.rtc.dataChannel || {ordered: false, maxRetransmits: 2};
opt.rtc.sdp = opt.rtc.sdp || {mandatory: {OfferToReceiveAudio: false, OfferToReceiveVideo: false}};
opt.announce = function(to){