Use rtcConfig

This commit is contained in:
Diego Rodríguez 2017-02-03 12:08:26 -05:00
parent 782c3d5810
commit d5117b72a2
No known key found for this signature in database
GPG key ID: 699A21547E317F10

12
app.js
View file

@ -1,12 +1,21 @@
/* global WebTorrent, angular, moment, prompt */
const VERSION = '0.17.0'
const VERSION = '0.17.1'
const tracker = ['wss://tracker.btorrent.xyz']
const opts = {
announce: tracker
}
const rtcConfig = {
'iceServers': [
{
'url': 'stun:stun.l.google.com:19305',
'urls': 'stun:stun.l.google.com:19305'
}
]
}
const debug = window.localStorage.getItem('debug') != null
const dbg = function (string, item, color) {
@ -25,6 +34,7 @@ const er = function (err, item) { dbg(err, item, '#FF0000') }
dbg(`Starting... v${VERSION}`)
const client = new WebTorrent({
rtcConfig: rtcConfig,
tracker: opts
})