getVideoThumbnail -> createVideoThumbnail
This commit is contained in:
parent
bb10240ee1
commit
57a56079fe
2 changed files with 3 additions and 3 deletions
|
@ -94,7 +94,7 @@ function addVideo (req, res, next) {
|
||||||
return next(err)
|
return next(err)
|
||||||
}
|
}
|
||||||
|
|
||||||
videos.getVideoThumbnail(videoFile.path, function (err, thumbnailName) {
|
videos.createVideoThumbnail(videoFile.path, function (err, thumbnailName) {
|
||||||
if (err) {
|
if (err) {
|
||||||
// TODO: unseed the video
|
// TODO: unseed the video
|
||||||
logger.error('Cannot make a thumbnail of the video file.')
|
logger.error('Cannot make a thumbnail of the video file.')
|
||||||
|
|
|
@ -20,7 +20,7 @@ const videos = {
|
||||||
createRemoteVideos: createRemoteVideos,
|
createRemoteVideos: createRemoteVideos,
|
||||||
getVideoDuration: getVideoDuration,
|
getVideoDuration: getVideoDuration,
|
||||||
getVideoState: getVideoState,
|
getVideoState: getVideoState,
|
||||||
getVideoThumbnail: getVideoThumbnail,
|
createVideoThumbnail: createVideoThumbnail,
|
||||||
removeVideosDataFromDisk: removeVideosDataFromDisk,
|
removeVideosDataFromDisk: removeVideosDataFromDisk,
|
||||||
removeRemoteVideos: removeRemoteVideos,
|
removeRemoteVideos: removeRemoteVideos,
|
||||||
seed: seed,
|
seed: seed,
|
||||||
|
@ -54,7 +54,7 @@ function getVideoState (video) {
|
||||||
return { exist: exist, owned: owned }
|
return { exist: exist, owned: owned }
|
||||||
}
|
}
|
||||||
|
|
||||||
function getVideoThumbnail (videoPath, callback) {
|
function createVideoThumbnail (videoPath, callback) {
|
||||||
const filename = pathUtils.basename(videoPath) + '.jpg'
|
const filename = pathUtils.basename(videoPath) + '.jpg'
|
||||||
ffmpeg(videoPath)
|
ffmpeg(videoPath)
|
||||||
.on('error', callback)
|
.on('error', callback)
|
||||||
|
|
Loading…
Reference in a new issue