mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-22 01:46:58 +01:00
add missing yup validations.
This commit is contained in:
parent
fa2cc5dbbd
commit
410f531441
@ -27,6 +27,9 @@ const schema = {
|
|||||||
password: yup.string(),
|
password: yup.string(),
|
||||||
role: yup.string().matches(/admin|user|view-only/i),
|
role: yup.string().matches(/admin|user|view-only/i),
|
||||||
}),
|
}),
|
||||||
|
DELETE: yup.object().shape({
|
||||||
|
userId: yup.string().uuid().required(),
|
||||||
|
}),
|
||||||
};
|
};
|
||||||
|
|
||||||
export default async (
|
export default async (
|
||||||
|
@ -28,6 +28,9 @@ const schema = {
|
|||||||
domain: yup.string(),
|
domain: yup.string(),
|
||||||
shareId: yup.string().matches(SHARE_ID_REGEX, { excludeEmptyString: true }).nullable(),
|
shareId: yup.string().matches(SHARE_ID_REGEX, { excludeEmptyString: true }).nullable(),
|
||||||
}),
|
}),
|
||||||
|
DELETE: yup.object().shape({
|
||||||
|
websiteId: yup.string().uuid().required(),
|
||||||
|
}),
|
||||||
};
|
};
|
||||||
|
|
||||||
export default async (
|
export default async (
|
||||||
|
Loading…
Reference in New Issue
Block a user