Skip to content
This repository has been archived by the owner on Jul 2, 2024. It is now read-only.

Commit

Permalink
Fix useless GraphQL error
Browse files Browse the repository at this point in the history
  • Loading branch information
sophstad committed Sep 15, 2023
1 parent 577deb5 commit 3166d09
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions src/gql/GQLWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -136,17 +136,11 @@ const authLink = (logout: () => void): ApolloLink =>
const logErrorsLink = onError(({ graphQLErrors, operation }) => {
if (Array.isArray(graphQLErrors)) {
graphQLErrors.forEach((gqlErr) => {
reportError(
{
message: "GraphQL Error",
name: gqlErr.message,
},
{
gqlErr,
operationName: operation.operationName,
variables: operation.variables,
}
).warning();
reportError(new Error(gqlErr.message), {
gqlErr,
operationName: operation.operationName,
variables: operation.variables,
}).warning();
});
}
// dont track network errors here because they are
Expand Down

0 comments on commit 3166d09

Please sign in to comment.