Remove 'strict()' not sure what it does

This commit is contained in:
powermaker450 2024-08-19 00:50:14 -04:00
parent 531b28501b
commit 3846034a44

View file

@ -1,7 +1,7 @@
import { object, string, number, InferType } from "yup";
export const reviewSchema = object({
username: string().strict(true).max(30).required(),
username: string().max(30).required(),
rating: number()
.positive()
.max(5)
@ -11,8 +11,8 @@ export const reviewSchema = object({
(number) => (number! * 10) % 5 === 0,
)
.required(),
title: string().strict(true).max(50).required(),
content: string().strict(true).max(2000).notRequired(),
title: string().max(50).required(),
content: string().max(2000).notRequired(),
});
export type Review = InferType<typeof reviewSchema>;