mirror of
https://github.com/strapi/strapi.git
synced 2025-11-18 02:58:05 +00:00
lifespan update not allowed
This commit is contained in:
parent
344d200582
commit
55634bacbd
@ -27,12 +27,6 @@ const apiTokenUpdateSchema = yup
|
|||||||
description: yup.string().nullable(),
|
description: yup.string().nullable(),
|
||||||
type: yup.string().oneOf(Object.values(constants.API_TOKEN_TYPE)).notNull(),
|
type: yup.string().oneOf(Object.values(constants.API_TOKEN_TYPE)).notNull(),
|
||||||
permissions: yup.array().of(yup.string()).nullable(),
|
permissions: yup.array().of(yup.string()).nullable(),
|
||||||
lifespan: yup
|
|
||||||
.number()
|
|
||||||
.integer()
|
|
||||||
.min(1)
|
|
||||||
.oneOf(Object.values(constants.API_TOKEN_LIFESPANS))
|
|
||||||
.nullable(),
|
|
||||||
})
|
})
|
||||||
.noUnknown()
|
.noUnknown()
|
||||||
.strict();
|
.strict();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user