diff options
Diffstat (limited to 'server/middlewares/validators/videos.ts')
-rw-r--r-- | server/middlewares/validators/videos.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/server/middlewares/validators/videos.ts b/server/middlewares/validators/videos.ts index ec452cade..013466487 100644 --- a/server/middlewares/validators/videos.ts +++ b/server/middlewares/validators/videos.ts | |||
@@ -33,7 +33,7 @@ function videosAddValidator (req: express.Request, res: express.Response, next: | |||
33 | next() | 33 | next() |
34 | }) | 34 | }) |
35 | .catch(err => { | 35 | .catch(err => { |
36 | logger.error('Error in getting duration from file.', { error: err }) | 36 | logger.error('Error in getting duration from file.', err) |
37 | res.status(400).send('Cannot retrieve metadata of the file.') | 37 | res.status(400).send('Cannot retrieve metadata of the file.') |
38 | }) | 38 | }) |
39 | }) | 39 | }) |
@@ -164,7 +164,7 @@ function checkVideoExists (id: string, res: express.Response, callback: () => vo | |||
164 | callback() | 164 | callback() |
165 | }) | 165 | }) |
166 | .catch(err => { | 166 | .catch(err => { |
167 | logger.error('Error in video request validator.', { error: err }) | 167 | logger.error('Error in video request validator.', err) |
168 | return res.sendStatus(500) | 168 | return res.sendStatus(500) |
169 | }) | 169 | }) |
170 | } | 170 | } |
@@ -190,7 +190,7 @@ function checkUserCanDeleteVideo (userId: number, res: express.Response, callbac | |||
190 | callback() | 190 | callback() |
191 | }) | 191 | }) |
192 | .catch(err => { | 192 | .catch(err => { |
193 | logger.error('Error in video request validator.', { error: err }) | 193 | logger.error('Error in video request validator.', err) |
194 | return res.sendStatus(500) | 194 | return res.sendStatus(500) |
195 | }) | 195 | }) |
196 | } | 196 | } |