MCPcopy Index your code
hub / github.com/webiny/webiny-js / createZodError

Function createZodError

packages/utils/src/createZodError.ts:48–54  ·  view source on GitHub ↗
(error: ZodError)

Source from the content-addressed store, hash-verified

46};
47
48export const createZodError = (error: ZodError) => {
49 return new WebinyError({
50 message: `Validation failed.`,
51 code: "VALIDATION_FAILED_INVALID_FIELDS",
52 data: createValidationErrorData(error)
53 });
54};
55
56export const parseZodError = (error: ZodError): ValidationIssue[] => {
57 return error.issues.map(issue => ({

Callers 15

getManifestFunction · 0.90
createWorkflowsSchemaFunction · 0.90
startWorkflowStateStepFunction · 0.90
validateMethod · 0.90
logValidationErrorFunction · 0.90
validateMethod · 0.90
getManifestFunction · 0.90
body.test.tsFile · 0.90
validateMethod · 0.90
validateTaskInputFunction · 0.90

Calls 1

Tested by

no test coverage detected