Skip to content

Commit

Permalink
fix(typebox): errors iteration (#537)
Browse files Browse the repository at this point in the history
  • Loading branch information
jorisre committed Apr 5, 2023
1 parent 4c62160 commit 4a65f85
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions mangle.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"mangle": {
"regex": "^_"
}
}
2 changes: 1 addition & 1 deletion typebox/src/typebox.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ const parseErrorSchema = (

export const typeboxResolver: Resolver =
(schema) => async (values, _, options) => {
const errors = [...Value.Errors(schema, values)];
const errors = Array.from(Value.Errors(schema, values));

options.shouldUseNativeValidation && validateFieldsNatively({}, options);

Expand Down

0 comments on commit 4a65f85

Please sign in to comment.