MCPcopy Create free account
hub / github.com/dailydotdev/apps / toClientError

Function toClientError

packages/shared/src/graphql/batch.ts:95–103  ·  view source on GitHub ↗
(
  item: BatchItem,
  response: BatchResponseItem,
  status: number,
)

Source from the content-addressed store, hash-verified

93 document.match(operationNamePattern)?.[1];
94
95const toClientError = (
96 item: BatchItem,
97 response: BatchResponseItem,
98 status: number,
99): ClientError =>
100 new ClientError(
101 { ...response, status },
102 { query: item.document, variables: item.variables },
103 );
104
105const rejectBatch = (items: BatchItem[], status: number, message: string) => {
106 items.forEach((item) => {

Callers 2

rejectBatchFunction · 0.85
flushFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected