mirror of
https://github.com/strapi/strapi.git
synced 2025-07-27 19:10:01 +00:00
16 lines
310 B
JavaScript
16 lines
310 B
JavaScript
'use strict';
|
|
|
|
const { yup, validateYupSchema } = require('@strapi/utils');
|
|
|
|
const roleUpdateSchema = yup
|
|
.object()
|
|
.shape({
|
|
name: yup.string().min(1),
|
|
description: yup.string().nullable(),
|
|
})
|
|
.noUnknown();
|
|
|
|
module.exports = {
|
|
validateRoleUpdateInput: validateYupSchema(roleUpdateSchema),
|
|
};
|