diff --git a/apps/dashboard/src/components/user-dialog.tsx b/apps/dashboard/src/components/user-dialog.tsx index c6d61f196..1bd909bef 100644 --- a/apps/dashboard/src/components/user-dialog.tsx +++ b/apps/dashboard/src/components/user-dialog.tsx @@ -49,7 +49,7 @@ export function UserDialog(props: { clientReadOnlyMetadata: jsonStringOrEmptySchema.default("null"), serverMetadata: jsonStringOrEmptySchema.default("null"), primaryEmailVerified: yup.boolean().optional(), - password: passwordSchema.test({ + password: passwordSchema.min(1).test({ name: 'password-required', message: "Password is required", test: (value, context) => { diff --git a/packages/stack-shared/src/schema-fields.ts b/packages/stack-shared/src/schema-fields.ts index c3bce768f..2838c557f 100644 --- a/packages/stack-shared/src/schema-fields.ts +++ b/packages/stack-shared/src/schema-fields.ts @@ -212,7 +212,7 @@ export const base64Schema = yupString().test("is-base64", (params) => `${params. if (value == null) return true; return isBase64(value); }); -export const passwordSchema = yupString().min(1).max(70); +export const passwordSchema = yupString().max(70); /** * A stricter email schema that does some additional checks for UX input. (Some emails are allowed by the spec, for