mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-02-25 18:55:32 -06:00
Fix tests
This commit is contained in:
parent
842a15732b
commit
17e2705f64
@ -10,8 +10,8 @@ let webtorrent: WebTorrent.Instance
|
||||
function webtorrentAdd (torrentId: string, refreshWebTorrent = false) {
|
||||
const WebTorrent = require('webtorrent')
|
||||
|
||||
if (!webtorrent) webtorrent = new WebTorrent()
|
||||
if (refreshWebTorrent === true) webtorrent = new WebTorrent()
|
||||
if (webtorrent && refreshWebTorrent) webtorrent.destroy()
|
||||
if (!webtorrent || refreshWebTorrent) webtorrent = new WebTorrent()
|
||||
|
||||
webtorrent.on('error', err => console.error('Error in webtorrent', err))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user