Skip to content

Commit

Permalink
fix: response.data is not always set (#397)
Browse files Browse the repository at this point in the history
  • Loading branch information
gr2m authored Jan 26, 2023
1 parent f10aa37 commit 125c968
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/wrap-request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ async function requestWithGraphqlErrorHandling(request, options) {
const response = await request(request, options);

if (
response.data &&
response.data.errors &&
/Something went wrong while executing your query/.test(
response.data.errors[0].message
Expand Down

0 comments on commit 125c968

Please sign in to comment.