MCPcopy Create free account
hub / github.com/OpenPipe/OpenPipe / errorFormatter

Function errorFormatter

app/src/server/api/trpc.ts:88–96  ·  view source on GitHub ↗
({ shape, error })

Source from the content-addressed store, hash-verified

86 .create({
87 transformer: superjson,
88 errorFormatter({ shape, error }) {
89 return {
90 ...shape,
91 data: {
92 ...shape.data,
93 zodError: error.cause instanceof ZodError ? error.cause.flatten() : null,
94 },
95 };
96 },
97 });
98
99/**

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected