X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmiddlewares%2Fvalidators%2Fvideos%2Fvideo-captions.ts;h=fd6dd151a235bb6fae5df1f26a6d6293bdf5af54;hb=396f6f0140b0f76162e2378fd5a61e2f888673ed;hp=dfb8fefc5c83a122832d09ec62f5ab4144a197c8;hpb=97eba003a9d0adcb0cab9190f566327b1417c7d3;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/middlewares/validators/videos/video-captions.ts b/server/middlewares/validators/videos/video-captions.ts index dfb8fefc5..fd6dd151a 100644 --- a/server/middlewares/validators/videos/video-captions.ts +++ b/server/middlewares/validators/videos/video-captions.ts @@ -18,7 +18,7 @@ const addVideoCaptionValidator = [ isValidVideoIdParam('videoId'), param('captionLanguage') - .custom(isVideoCaptionLanguageValid).not().isEmpty().withMessage('Should have a valid caption language'), + .custom(isVideoCaptionLanguageValid).not().isEmpty(), body('captionfile') .custom((_, { req }) => isVideoCaptionFile(req.files, 'captionfile'))