+ body('targetUrl')
+ .optional()
+ .custom(isVideoImportTargetUrlValid).withMessage('Should have a valid video import target URL'),
+ body('magnetUri')
+ .optional()
+ .custom(isVideoMagnetUriValid).withMessage('Should have a valid video magnet URI'),
+ body('torrentfile')
+ .custom((value, { req }) => isVideoImportTorrentFile(req.files)).withMessage(
+ 'This torrent file is not supported or too large. Please, make sure it is of the following type: '
+ + CONSTRAINTS_FIELDS.VIDEO_IMPORTS.TORRENT_FILE.EXTNAME.join(', ')
+ ),