module GraphQL::StaticValidation::MutationRootExists
Public Instance Methods
(GraphQL::Language::Nodes::OperationDefinition node, GraphQL::Language::Nodes::AbstractNode? _parent) → void
Source
# File lib/graphql/static_validation/rules/mutation_root_exists.rb, line 9 def on_operation_definition(node, _parent) if node.operation_type == 'mutation' && context.types.mutation_root.nil? add_error(GraphQL::StaticValidation::MutationRootExistsError.new( 'Schema is not configured for mutations', nodes: node )) else super end end
Calls superclass method