aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/thumbnail.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-04-24 09:56:25 +0200
committerChocobozzz <me@florianbigard.com>2019-04-24 16:26:22 +0200
commit2fb5b3a55aeebcc77f4b3a0c029bbf0738ef0063 (patch)
tree3f03677870548c648070ac138a2b5ca36ee8fbeb /server/lib/thumbnail.ts
parentb876eaf11a1ed9683664d94767ca684ba5b77753 (diff)
downloadPeerTube-2fb5b3a55aeebcc77f4b3a0c029bbf0738ef0063.tar.gz
PeerTube-2fb5b3a55aeebcc77f4b3a0c029bbf0738ef0063.tar.zst
PeerTube-2fb5b3a55aeebcc77f4b3a0c029bbf0738ef0063.zip
Relax videos list thumbnail api join
Diffstat (limited to 'server/lib/thumbnail.ts')
-rw-r--r--server/lib/thumbnail.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/thumbnail.ts b/server/lib/thumbnail.ts
index 8ad82ee80..4ba521b97 100644
--- a/server/lib/thumbnail.ts
+++ b/server/lib/thumbnail.ts
@@ -16,7 +16,7 @@ function createPlaylistMiniatureFromExisting (inputPath: string, playlist: Video
16 const { filename, outputPath, height, width, existingThumbnail } = buildMetadataFromPlaylist(playlist, size) 16 const { filename, outputPath, height, width, existingThumbnail } = buildMetadataFromPlaylist(playlist, size)
17 const type = ThumbnailType.MINIATURE 17 const type = ThumbnailType.MINIATURE
18 18
19 const thumbnailCreator = () => processImage({ path: inputPath }, outputPath, { width, height }, keepOriginal) 19 const thumbnailCreator = () => processImage(inputPath, outputPath, { width, height }, keepOriginal)
20 return createThumbnailFromFunction({ thumbnailCreator, filename, height, width, type, existingThumbnail }) 20 return createThumbnailFromFunction({ thumbnailCreator, filename, height, width, type, existingThumbnail })
21} 21}
22 22
@@ -37,7 +37,7 @@ function createVideoMiniatureFromUrl (url: string, video: VideoModel, type: Thum
37 37
38function createVideoMiniatureFromExisting (inputPath: string, video: VideoModel, type: ThumbnailType, size?: ImageSize) { 38function createVideoMiniatureFromExisting (inputPath: string, video: VideoModel, type: ThumbnailType, size?: ImageSize) {
39 const { filename, outputPath, height, width, existingThumbnail } = buildMetadataFromVideo(video, type, size) 39 const { filename, outputPath, height, width, existingThumbnail } = buildMetadataFromVideo(video, type, size)
40 const thumbnailCreator = () => processImage({ path: inputPath }, outputPath, { width, height }) 40 const thumbnailCreator = () => processImage(inputPath, outputPath, { width, height })
41 41
42 return createThumbnailFromFunction({ thumbnailCreator, filename, height, width, type, existingThumbnail }) 42 return createThumbnailFromFunction({ thumbnailCreator, filename, height, width, type, existingThumbnail })
43} 43}