diff --git a/client/api/src/main/java/io/smallrye/graphql/client/GraphQLClientException.java b/client/api/src/main/java/io/smallrye/graphql/client/GraphQLClientException.java index 27a90b062..e6e6a1b71 100644 --- a/client/api/src/main/java/io/smallrye/graphql/client/GraphQLClientException.java +++ b/client/api/src/main/java/io/smallrye/graphql/client/GraphQLClientException.java @@ -24,7 +24,7 @@ public GraphQLClientException(String message, GraphQLError error) { public GraphQLClientException(String message, List errors) { super(message); - this.errors = requireNonNull(errors).stream().filter(Objects::nonNull).collect(Collectors.toList()); + this.errors = requireNonNull(errors).stream().map(Objects::requireNonNull).collect(Collectors.toList()); } @Override