aboutsummaryrefslogtreecommitdiffhomepage
path: root/server
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-03-08 09:42:22 +0100
committerChocobozzz <me@florianbigard.com>2022-03-08 09:42:22 +0100
commitf6f48301a9ad392759d714d2cff13f1564942a50 (patch)
tree581654f7ed23b3912484cd5091864830b903127b /server
parentc47c3bcb0a9265d2a414ec96075052f8619d3f21 (diff)
downloadPeerTube-f6f48301a9ad392759d714d2cff13f1564942a50.tar.gz
PeerTube-f6f48301a9ad392759d714d2cff13f1564942a50.tar.zst
PeerTube-f6f48301a9ad392759d714d2cff13f1564942a50.zip
More robust transcoding checker
Diffstat (limited to 'server')
-rw-r--r--server/middlewares/validators/videos/video-transcoding.ts2
1 files changed, 1 insertions, 1 deletions
diff --git a/server/middlewares/validators/videos/video-transcoding.ts b/server/middlewares/validators/videos/video-transcoding.ts
index 34f231d45..da6638f4d 100644
--- a/server/middlewares/validators/videos/video-transcoding.ts
+++ b/server/middlewares/validators/videos/video-transcoding.ts
@@ -37,7 +37,7 @@ const createTranscodingValidator = [
37 37
38 // Prefer using job info table instead of video state because before 4.0 failed transcoded video were stuck in "TO_TRANSCODE" state 38 // Prefer using job info table instead of video state because before 4.0 failed transcoded video were stuck in "TO_TRANSCODE" state
39 const info = await VideoJobInfoModel.load(video.id) 39 const info = await VideoJobInfoModel.load(video.id)
40 if (info && info.pendingTranscode !== 0) { 40 if (info && info.pendingTranscode > 0) {
41 return res.fail({ 41 return res.fail({
42 status: HttpStatusCode.CONFLICT_409, 42 status: HttpStatusCode.CONFLICT_409,
43 message: 'This video is already being transcoded' 43 message: 'This video is already being transcoded'