Sha256: 171f712d9671f94a330e885efc016375ea2c368b42726dc03dd03a5e61ffd495
Contents?: true
Size: 630 Bytes
Versions: 120
Compression:
Stored size: 630 Bytes
Contents
# frozen_string_literal: true module GraphQL module StaticValidation module FragmentsAreFinite def on_document(_n, _p) super dependency_map = context.dependencies dependency_map.cyclical_definitions.each do |defn| if defn.node.is_a?(GraphQL::Language::Nodes::FragmentDefinition) add_error(GraphQL::StaticValidation::FragmentsAreFiniteError.new( "Fragment #{defn.name} contains an infinite loop", nodes: defn.node, path: defn.path, name: defn.name )) end end end end end end
Version data entries
120 entries across 120 versions & 2 rubygems