Skip to content

Commit c6535d0

Browse files
committed
fix: send zod error instead of zod issues
1 parent be59411 commit c6535d0

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

packages/core/src/utils.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,12 +203,13 @@ export function withValidator<
203203
const response = await handler(payload)
204204

205205
const validationError = validateResponseBody(schema, response.status, response.body)
206+
206207
if (validationError) {
207208
return {
208209
status: 500,
209210
body: {
210211
error: 'Response validation failed',
211-
details: validationError.issues,
212+
details: validationError,
212213
},
213214
}
214215
}

0 commit comments

Comments
 (0)