Skip to content

Commit

Permalink
hideSuggestions exists on context
Browse files Browse the repository at this point in the history
  • Loading branch information
benjie committed Feb 26, 2025
1 parent 5053439 commit 3d0f625
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/execution/collectFields.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,6 @@ function collectFieldsImpl(
selection,
variableValues,
fragmentVariableValues,
hideSuggestions,
)
) {
continue;
Expand All @@ -208,7 +207,6 @@ function collectFieldsImpl(
selection,
variableValues,
fragmentVariableValues,
hideSuggestions,
) ||
!doesFragmentConditionMatch(schema, selection, runtimeType)
) {
Expand Down Expand Up @@ -255,7 +253,6 @@ function collectFieldsImpl(
selection,
variableValues,
fragmentVariableValues,
hideSuggestions,
)
) {
continue;
Expand Down Expand Up @@ -356,7 +353,6 @@ function shouldIncludeNode(
node: FragmentSpreadNode | FieldNode | InlineFragmentNode,
variableValues: VariableValues,
fragmentVariableValues: VariableValues | undefined,
hideSuggestions: Maybe<boolean>,
): boolean {
const skipDirectiveNode = node.directives?.find(
(directive) => directive.name.value === GraphQLSkipDirective.name,
Expand All @@ -371,7 +367,7 @@ function shouldIncludeNode(
GraphQLSkipDirective.args,
variableValues,
fragmentVariableValues,
hideSuggestions,
context.hideSuggestions,
)
: undefined;
if (skip?.if === true) {
Expand All @@ -391,7 +387,7 @@ function shouldIncludeNode(
GraphQLIncludeDirective.args,
variableValues,
fragmentVariableValues,
hideSuggestions,
context.hideSuggestions,
)
: undefined;
if (include?.if === false) {
Expand Down

0 comments on commit 3d0f625

Please sign in to comment.