From f912d820025b3bc142a0cdabcbc0e69c734142bd Mon Sep 17 00:00:00 2001 From: Torjus Date: Mon, 30 Jul 2018 09:38:06 +0200 Subject: [PATCH] Use TURN server in WebTorrent config --- app/lib/components/Chat/FileSharing.jsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/app/lib/components/Chat/FileSharing.jsx b/app/lib/components/Chat/FileSharing.jsx index f2b248a..339b346 100644 --- a/app/lib/components/Chat/FileSharing.jsx +++ b/app/lib/components/Chat/FileSharing.jsx @@ -5,9 +5,15 @@ import dragDrop from 'drag-drop'; import * as stateActions from '../../redux/stateActions'; import * as requestActions from '../../redux/requestActions'; import { store } from '../../store'; -import { promisify } from 'util'; +import config from '../../../config'; -export const client = new WebTorrent(); +export const client = new WebTorrent({ + tracker: { + rtcConfig: { + iceServers: config.turnServers + } + } +}); const notifyPeers = (file) => {