X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fmiddlewares%2Fvalidators%2Fthemes.ts;h=080b3e096303fc12c8d2c73e0039b8465063eac2;hb=e364e31e25bd1d4b8d801c845a96d6be708f0a18;hp=c130801a01cfb24c7328f969781dcf1f10bba8b6;hpb=a85d530384761a0af833caac9b38b9834517c9fa;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/middlewares/validators/themes.ts b/server/middlewares/validators/themes.ts index c130801a0..080b3e096 100644 --- a/server/middlewares/validators/themes.ts +++ b/server/middlewares/validators/themes.ts @@ -2,7 +2,7 @@ import express from 'express' import { param } from 'express-validator' import { HttpStatusCode } from '../../../shared/models/http/http-error-codes' import { isSafePath } from '../../helpers/custom-validators/misc' -import { isPluginNameValid, isPluginVersionValid } from '../../helpers/custom-validators/plugins' +import { isPluginNameValid, isPluginStableOrUnstableVersionValid } from '../../helpers/custom-validators/plugins' import { PluginManager } from '../../lib/plugins/plugin-manager' import { areValidationErrors } from './shared' @@ -10,7 +10,7 @@ const serveThemeCSSValidator = [ param('themeName') .custom(isPluginNameValid), param('themeVersion') - .custom(isPluginVersionValid), + .custom(isPluginStableOrUnstableVersionValid), param('staticEndpoint') .custom(isSafePath),