Fix tests
authorChocobozzz <me@florianbigard.com>
Thu, 30 Jan 2020 07:17:31 +0000 (08:17 +0100)
committerChocobozzz <me@florianbigard.com>
Thu, 30 Jan 2020 07:17:31 +0000 (08:17 +0100)
server/middlewares/validators/videos/videos.ts

index 00ee375cb7f549970df88c4788edf456c777987d..6733d9dec4366cf32b821a7b3a03d715ca0e00d6 100644 (file)
@@ -81,7 +81,7 @@ const videosAddValidator = getCommonVideoEditAttributes().concat([
       duration = await getDurationFromVideoFile(videoFile.path)
     } catch (err) {
       logger.error('Invalid input file in videosAddValidator.', { err })
-      res.status(422)
+      res.status(400)
          .json({ error: 'Invalid input file.' })
 
       return cleanUpReqFiles(req)