X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmiddlewares%2Fvalidators%2Fthemes.ts;h=f6a8c2d923158a5b6a0fc849abc4e06e2dbd9b49;hb=396f6f0140b0f76162e2378fd5a61e2f888673ed;hp=7b9fee85884c69615c38e3594867b74bef83b579;hpb=97eba003a9d0adcb0cab9190f566327b1417c7d3;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/middlewares/validators/themes.ts b/server/middlewares/validators/themes.ts index 7b9fee858..f6a8c2d92 100644 --- a/server/middlewares/validators/themes.ts +++ b/server/middlewares/validators/themes.ts @@ -8,9 +8,12 @@ import { PluginManager } from '../../lib/plugins/plugin-manager' import { areValidationErrors } from './shared' const serveThemeCSSValidator = [ - param('themeName').custom(isPluginNameValid).withMessage('Should have a valid theme name'), - param('themeVersion').custom(isPluginVersionValid).withMessage('Should have a valid theme version'), - param('staticEndpoint').custom(isSafePath).withMessage('Should have a valid static endpoint'), + param('themeName') + .custom(isPluginNameValid), + param('themeVersion') + .custom(isPluginVersionValid), + param('staticEndpoint') + .custom(isSafePath), (req: express.Request, res: express.Response, next: express.NextFunction) => { logger.debug('Checking serveThemeCSS parameters', { parameters: req.params })