aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers/ffprobe-utils.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-12-03 09:38:24 +0100
committerChocobozzz <me@florianbigard.com>2020-12-03 10:05:10 +0100
commit4a54a93941d1c095bf249331df799c51e39c3774 (patch)
tree3a2b2958bf6f845e375790818ec475a1cb2dc23c /server/helpers/ffprobe-utils.ts
parent09c55770bcc96785fb1f199b4cd8ce66b545486a (diff)
downloadPeerTube-4a54a93941d1c095bf249331df799c51e39c3774.tar.gz
PeerTube-4a54a93941d1c095bf249331df799c51e39c3774.tar.zst
PeerTube-4a54a93941d1c095bf249331df799c51e39c3774.zip
Fix live invalid save replay duration
Diffstat (limited to 'server/helpers/ffprobe-utils.ts')
-rw-r--r--server/helpers/ffprobe-utils.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/helpers/ffprobe-utils.ts b/server/helpers/ffprobe-utils.ts
index 1cf397767..4dea6283c 100644
--- a/server/helpers/ffprobe-utils.ts
+++ b/server/helpers/ffprobe-utils.ts
@@ -164,7 +164,7 @@ async function getVideoFileBitrate (path: string, existingProbe?: ffmpeg.Ffprobe
164async function getDurationFromVideoFile (path: string, existingProbe?: ffmpeg.FfprobeData) { 164async function getDurationFromVideoFile (path: string, existingProbe?: ffmpeg.FfprobeData) {
165 const metadata = await getMetadataFromFile(path, existingProbe) 165 const metadata = await getMetadataFromFile(path, existingProbe)
166 166
167 return Math.floor(metadata.format.duration) 167 return Math.round(metadata.format.duration)
168} 168}
169 169
170async function getVideoStreamFromFile (path: string, existingProbe?: ffmpeg.FfprobeData) { 170async function getVideoStreamFromFile (path: string, existingProbe?: ffmpeg.FfprobeData) {