aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video/video-file.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-02-18 11:28:00 +0100
committerChocobozzz <chocobozzz@cpy.re>2021-02-18 13:38:09 +0100
commit8efc27bf14f1fe3ed23cd8a6d2de1f0918a7f769 (patch)
tree863daf231cf4a66d9e5abf1cfe4fbe2b742cd856 /server/models/video/video-file.ts
parentf66db4d5c851fe87bb71cccee96926000f59a15b (diff)
downloadPeerTube-8efc27bf14f1fe3ed23cd8a6d2de1f0918a7f769.tar.gz
PeerTube-8efc27bf14f1fe3ed23cd8a6d2de1f0918a7f769.tar.zst
PeerTube-8efc27bf14f1fe3ed23cd8a6d2de1f0918a7f769.zip
Cleanup
Diffstat (limited to 'server/models/video/video-file.ts')
-rw-r--r--server/models/video/video-file.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/models/video/video-file.ts b/server/models/video/video-file.ts
index 5a3706259..4df2c20bc 100644
--- a/server/models/video/video-file.ts
+++ b/server/models/video/video-file.ts
@@ -423,7 +423,7 @@ export class VideoFileModel extends Model {
423 return !!this.videoStreamingPlaylistId 423 return !!this.videoStreamingPlaylistId
424 } 424 }
425 425
426 getFileUrl (video: MVideoWithHost) { 426 getFileUrl (video: MVideo) {
427 if (!this.Video) this.Video = video as VideoModel 427 if (!this.Video) this.Video = video as VideoModel
428 428
429 if (video.isOwned()) return WEBSERVER.URL + this.getFileStaticPath(video) 429 if (video.isOwned()) return WEBSERVER.URL + this.getFileStaticPath(video)
@@ -449,7 +449,7 @@ export class VideoFileModel extends Model {
449 return buildRemoteVideoBaseUrl(video, path) 449 return buildRemoteVideoBaseUrl(video, path)
450 } 450 }
451 451
452 getRemoteTorrentUrl (video: MVideoWithHost) { 452 getRemoteTorrentUrl (video: MVideo) {
453 if (video.isOwned()) throw new Error(`Video ${video.url} is not a remote video`) 453 if (video.isOwned()) throw new Error(`Video ${video.url} is not a remote video`)
454 454
455 return this.torrentUrl 455 return this.torrentUrl