Skip to content

Commit

Permalink
min 0 validation on number
Browse files Browse the repository at this point in the history
  • Loading branch information
diegoalzate committed May 21, 2024
1 parent 46f5a43 commit 179d8d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/berlin/src/pages/Register.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -855,7 +855,7 @@ function NumberInput(props: {
return true;
}

const v = z.string().min(1, 'Value is required').safeParse(value);
const v = z.coerce.number().min(0, 'Value is required').safeParse(value);

if (v.success) {
return true;
Expand Down

0 comments on commit 179d8d8

Please sign in to comment.