Skip to content

Commit

Permalink
fix: the return structure in validatorCompiler() is wrong
Browse files Browse the repository at this point in the history
  • Loading branch information
ShookLyngs committed Aug 27, 2024
1 parent 3374b6a commit 987a3e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ export const validatorCompiler: FastifySchemaCompiler<ZodAny> =
(data) => {
const result = schema.safeParse(data);
if (result.success) {
return result.data;
return { value: result.data };
}

const error = result.error;
Expand Down

0 comments on commit 987a3e0

Please sign in to comment.