Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Fixed
-
GraphQL Core 0.0.6
-
None
Description
Problem
In case GraphQLError does not contain any Location information, rather when the list of locations will be null [0], then a NullPointerException is thrown. This causes a non-meaningful response to be sent back to client.
For example, the following query will cause a NPE:
{ article(_path: "/non-existent/path/to/an-article")
{
_path
}
}
Proposed solution:
Should be a null check for error.getLocations().
Attachments
Issue Links
- causes
-
SLING-9872 Avoid logging unsanitized input
- Closed
- links to