class GraphQL::Client::Errors

def include?(field)

otherwise false.
Returns true if the error messages include an error for the given field,

data.errors.include?("version") # => false
data.errors.include?("node") # => true
data.errors.messages # => {"node"=>["couldn't find node by id", "unauthorized"]}

Public: Check if there are any errors on a given field.
def include?(field)
  self[field].any?
end