X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;ds=sidebyside;f=server%2Flib%2Fvideo-paths.ts;h=53fc8e81d5fcf6f82cb7016c0747701eb647c9ab;hb=053aed43fb255b4ae4324a845534f2f562c3b6cc;hp=b6cb39d25ad9e6a4112299ff00afd406ded9c110;hpb=3bc68dfd6183078fb56b53e24e74f889c85c4ae0;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/lib/video-paths.ts b/server/lib/video-paths.ts index b6cb39d25..53fc8e81d 100644 --- a/server/lib/video-paths.ts +++ b/server/lib/video-paths.ts @@ -9,7 +9,7 @@ import { extractVideo } from '@server/helpers/video' function getVideoFilename (videoOrPlaylist: MVideo | MStreamingPlaylistVideo, videoFile: MVideoFile) { const video = extractVideo(videoOrPlaylist) - if (isStreamingPlaylist(videoOrPlaylist)) { + if (videoFile.isHLS()) { return generateVideoStreamingPlaylistName(video.uuid, videoFile.resolution) } @@ -25,7 +25,7 @@ function generateWebTorrentVideoName (uuid: string, resolution: number, extname: } function getVideoFilePath (videoOrPlaylist: MVideo | MStreamingPlaylistVideo, videoFile: MVideoFile, isRedundancy = false) { - if (isStreamingPlaylist(videoOrPlaylist)) { + if (videoFile.isHLS()) { const video = extractVideo(videoOrPlaylist) return join(getHLSDirectory(video), getVideoFilename(videoOrPlaylist, videoFile))