Skip to content

Commit

Permalink
Remove needless return value
Browse files Browse the repository at this point in the history
  • Loading branch information
rmosolgo committed Apr 26, 2024
1 parent f5b162e commit 108342c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions lib/graphql/execution/interpreter/runtime.rb
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ def evaluate_selections(is_eager_selection, gathered_selections, selections_resu
gathered_selections.each do |result_name, field_ast_nodes_or_ast_node|
@dataloader.append_job {
runtime_state = get_current_runtime_state
field_result = evaluate_selection(
evaluate_selection(
result_name, field_ast_nodes_or_ast_node, is_eager_selection, selections_result, parent_object, runtime_state
)
finished_jobs += 1
Expand Down Expand Up @@ -384,15 +384,11 @@ def evaluate_selection_with_resolved_keyword_args(kwarg_arguments, resolved_argu
end
end
end

# If this field is a root mutation field, immediately resolve
# all of its child fields before moving on to the next root mutation field.
# (Subselections of this mutation will still be resolved level-by-level.)
if is_eager_field
Interpreter::Resolve.resolve_all([field_result], @dataloader)
else
# Return this from `after_lazy` because it might be another lazy that needs to be resolved
field_result
end
end

Expand Down

0 comments on commit 108342c

Please sign in to comment.