修复无法更新脚本内容为空

This commit is contained in:
whyour 2022-06-08 23:57:22 +08:00
parent 559defc8d6
commit b009d3e3fd

View File

@ -133,7 +133,7 @@ export default (app: Router) => {
body: Joi.object({ body: Joi.object({
filename: Joi.string().required(), filename: Joi.string().required(),
path: Joi.string().optional().allow(''), path: Joi.string().optional().allow(''),
content: Joi.string().required(), content: Joi.string().required().allow(''),
}), }),
}), }),
async (req: Request, res: Response, next: NextFunction) => { async (req: Request, res: Response, next: NextFunction) => {