aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/video
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-11-07 10:25:24 +0100
committerChocobozzz <me@florianbigard.com>2022-11-07 10:25:24 +0100
commita32bf8cd20212b903d3fa478e629f051eb77fecc (patch)
tree2a0372477ae2d76c31fc749054e78f1d067807d3 /server/models/video
parent11ae7e2917ddf6e3c8e53d0855fd786163112d59 (diff)
downloadPeerTube-a32bf8cd20212b903d3fa478e629f051eb77fecc.tar.gz
PeerTube-a32bf8cd20212b903d3fa478e629f051eb77fecc.tar.zst
PeerTube-a32bf8cd20212b903d3fa478e629f051eb77fecc.zip
Fix running again transcoding on a video only file
Diffstat (limited to 'server/models/video')
-rw-r--r--server/models/video/video.ts4
1 files changed, 3 insertions, 1 deletions
diff --git a/server/models/video/video.ts b/server/models/video/video.ts
index f3907bed4..56cc45cfe 100644
--- a/server/models/video/video.ts
+++ b/server/models/video/video.ts
@@ -34,7 +34,7 @@ import { isVideoInPrivateDirectory } from '@server/lib/video-privacy'
34import { getServerActor } from '@server/models/application/application' 34import { getServerActor } from '@server/models/application/application'
35import { ModelCache } from '@server/models/model-cache' 35import { ModelCache } from '@server/models/model-cache'
36import { buildVideoEmbedPath, buildVideoWatchPath, pick } from '@shared/core-utils' 36import { buildVideoEmbedPath, buildVideoWatchPath, pick } from '@shared/core-utils'
37import { ffprobePromise, getAudioStream, uuidToShort } from '@shared/extra-utils' 37import { ffprobePromise, getAudioStream, hasAudioStream, uuidToShort } from '@shared/extra-utils'
38import { 38import {
39 ResultList, 39 ResultList,
40 ThumbnailType, 40 ThumbnailType,
@@ -1751,9 +1751,11 @@ export class VideoModel extends Model<Partial<AttributesOnly<VideoModel>>> {
1751 const probe = await ffprobePromise(originalFilePath) 1751 const probe = await ffprobePromise(originalFilePath)
1752 1752
1753 const { audioStream } = await getAudioStream(originalFilePath, probe) 1753 const { audioStream } = await getAudioStream(originalFilePath, probe)
1754 const hasAudio = await hasAudioStream(originalFilePath, probe)
1754 1755
1755 return { 1756 return {
1756 audioStream, 1757 audioStream,
1758 hasAudio,
1757 1759
1758 ...await getVideoStreamDimensionsInfo(originalFilePath, probe) 1760 ...await getVideoStreamDimensionsInfo(originalFilePath, probe)
1759 } 1761 }