X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;ds=sidebyside;f=server%2Fhelpers%2Fwebtorrent.ts;h=b458e86d2a0dc1a671962f03a1ef744c4d745210;hb=9ab330b90decf4edf152ff8e1d2948c065766b2c;hp=6d87c74f7ec8b9a31dc8a5fcce653d017634acbf;hpb=3545e72c686ff1725bbdfd8d16d693e2f4aa75a3;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/helpers/webtorrent.ts b/server/helpers/webtorrent.ts index 6d87c74f7..b458e86d2 100644 --- a/server/helpers/webtorrent.ts +++ b/server/helpers/webtorrent.ts @@ -165,7 +165,7 @@ function generateMagnetUri ( const xs = videoFile.getTorrentUrl() const announce = trackerUrls - let urlList = video.requiresAuth(video.uuid) + let urlList = video.hasPrivateStaticPath() ? [] : [ videoFile.getFileUrl(video) ] @@ -243,7 +243,7 @@ function buildAnnounceList () { } function buildUrlList (video: MVideo, videoFile: MVideoFile) { - if (video.requiresAuth(video.uuid)) return [] + if (video.hasPrivateStaticPath()) return [] return [ videoFile.getFileUrl(video) ] }