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.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts
index ed1f21d66..3532c753e 100644
--- a/server/controllers/api/videos/index.ts
+++ b/server/controllers/api/videos/index.ts
@@ -63,7 +63,7 @@ const storage = multer.diskStorage({
63 cb(null, filename + '.' + extension) 63 cb(null, filename + '.' + extension)
64 }) 64 })
65 .catch(err => { 65 .catch(err => {
66 logger.error('Cannot generate random string for file name.', { error: err }) 66 logger.error('Cannot generate random string for file name.', err)
67 throw err 67 throw err
68 }) 68 })
69 } 69 }
@@ -304,7 +304,7 @@ function updateVideo (req: express.Request, res: express.Response) {
304 logger.info('Video with name %s updated.', videoInstance.name) 304 logger.info('Video with name %s updated.', videoInstance.name)
305 }) 305 })
306 .catch(err => { 306 .catch(err => {
307 logger.debug('Cannot update the video.', { error: err }) 307 logger.debug('Cannot update the video.', err)
308 308
309 // Force fields we want to update 309 // Force fields we want to update
310 // If the transaction is retried, sequelize will think the object has not changed 310 // If the transaction is retried, sequelize will think the object has not changed
@@ -333,7 +333,7 @@ function getVideo (req: express.Request, res: express.Response, next: express.Ne
333 } 333 }
334 return quickAndDirtyUpdateVideoToFriends(qaduParams) 334 return quickAndDirtyUpdateVideoToFriends(qaduParams)
335 }) 335 })
336 .catch(err => logger.error('Cannot add view to video %d.', videoInstance.id, { error: err })) 336 .catch(err => logger.error('Cannot add view to video %d.', videoInstance.id, err))
337 } else { 337 } else {
338 // Just send the event to our friends 338 // Just send the event to our friends
339 const eventParams = { 339 const eventParams = {
@@ -359,7 +359,7 @@ function removeVideo (req: express.Request, res: express.Response, next: express
359 videoInstance.destroy() 359 videoInstance.destroy()
360 .then(() => res.type('json').status(204).end()) 360 .then(() => res.type('json').status(204).end())
361 .catch(err => { 361 .catch(err => {
362 logger.error('Errors when removed the video.', { error: err }) 362 logger.error('Errors when removed the video.', err)
363 return next(err) 363 return next(err)
364 }) 364 })
365} 365}