aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/controllers/api/videos/index.ts')
-rw-r--r--server/controllers/api/videos/index.ts6
1 files changed, 2 insertions, 4 deletions
diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts
index a593f7076..1d61f8427 100644
--- a/server/controllers/api/videos/index.ts
+++ b/server/controllers/api/videos/index.ts
@@ -12,8 +12,7 @@ import {
12 VIDEO_CATEGORIES, 12 VIDEO_CATEGORIES,
13 VIDEO_LANGUAGES, 13 VIDEO_LANGUAGES,
14 VIDEO_LICENCES, 14 VIDEO_LICENCES,
15 VIDEO_PRIVACIES, 15 VIDEO_PRIVACIES
16 VIDEO_TRANSCODING_FPS
17} from '../../../initializers/constants' 16} from '../../../initializers/constants'
18import { 17import {
19 changeVideoChannelShare, 18 changeVideoChannelShare,
@@ -308,7 +307,7 @@ async function addVideo (req: express.Request, res: express.Response) {
308 } 307 }
309 } 308 }
310 309
311 await JobQueue.Instance.createJob({ type: 'video-transcoding', payload: dataInput }) 310 await JobQueue.Instance.createJobWithPromise({ type: 'video-transcoding', payload: dataInput })
312 } 311 }
313 312
314 Hooks.runAction('action:api.video.uploaded', { video: videoCreated }) 313 Hooks.runAction('action:api.video.uploaded', { video: videoCreated })
@@ -453,7 +452,6 @@ async function getVideo (req: express.Request, res: express.Response) {
453 452
454 if (video.isOutdated()) { 453 if (video.isOutdated()) {
455 JobQueue.Instance.createJob({ type: 'activitypub-refresher', payload: { type: 'video', url: video.url } }) 454 JobQueue.Instance.createJob({ type: 'activitypub-refresher', payload: { type: 'video', url: video.url } })
456 .catch(err => logger.error('Cannot create AP refresher job for video %s.', video.url, { err }))
457 } 455 }
458 456
459 return res.json(video.toFormattedDetailsJSON()) 457 return res.json(video.toFormattedDetailsJSON())