Skip to content

Commit

Permalink
Adding location to error location
Browse files Browse the repository at this point in the history
  • Loading branch information
harishkannarao committed Mar 6, 2024
1 parent 36a9b58 commit 1dc04b4
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ public GraphQLError handle(ArtificialException ex, DataFetchingEnvironment dataF
logger.error(message, ex);
return GraphQLError.newError()
.errorType(ErrorType.BAD_REQUEST)
.location(dataFetchingEnvironment.getOperationDefinition().getSelectionSet().getSourceLocation())
.path(dataFetchingEnvironment.getExecutionStepInfo().getPath())
.message(message)
.build();
Expand Down

0 comments on commit 1dc04b4

Please sign in to comment.