Skip to content

Commit

Permalink
Merge pull request #5125 from francisbeaudoin/master
Browse files Browse the repository at this point in the history
Optimization - Skip processing non-existing fields in FieldsWillMerge
  • Loading branch information
rmosolgo authored Oct 22, 2024
2 parents 56265cd + 8c0e258 commit ec80ea5
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/graphql/static_validation/rules/fields_will_merge.rb
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,7 @@ def find_conflicts_within(response_keys)

def find_conflict(response_key, field1, field2, mutually_exclusive: false)
return if @conflict_count >= context.max_errors
return if field1.definition.nil? || field2.definition.nil?

node1 = field1.node
node2 = field2.node
Expand Down

0 comments on commit ec80ea5

Please sign in to comment.