From c37e305342c8655325f9606aa1f4b29abc471b39 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Tue, 6 Jun 2023 11:14:13 +0200 Subject: Fix CI tests --- server/middlewares/validators/videos/videos.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'server/middlewares/validators') diff --git a/server/middlewares/validators/videos/videos.ts b/server/middlewares/validators/videos/videos.ts index fc2f95aa5..9034772c0 100644 --- a/server/middlewares/validators/videos/videos.ts +++ b/server/middlewares/validators/videos/videos.ts @@ -223,10 +223,12 @@ const videosAddResumableInitValidator = getCommonVideoEditAttributes().concat([ if (!isValidPasswordProtectedPrivacy(req, res)) return cleanup() - // multer required unsetting the Content-Type, now we can set it for node-uploadx + // Multer required unsetting the Content-Type, now we can set it for node-uploadx req.headers['content-type'] = 'application/json; charset=utf-8' - // place previewfile in metadata so that uploadx saves it in .META + + // Place thumbnail/previewfile in metadata so that uploadx saves it in .META if (req.files?.['previewfile']) req.body.previewfile = req.files['previewfile'] + if (req.files?.['thumbnailfile']) req.body.thumbnailfile = req.files['thumbnailfile'] return next() } -- cgit v1.2.3