Skip to content

Commit

Permalink
fix collect fields
Browse files Browse the repository at this point in the history
have to add test case
  • Loading branch information
yaacovCR committed Sep 6, 2024
1 parent 4191710 commit db670e9
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/execution/collectFields.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,14 +134,16 @@ export function collectSubfields(
const newDeferUsages: Array<DeferUsage> = [];

for (const fieldDetail of fieldGroup) {
const node = fieldDetail.node;
if (node.selectionSet) {
const selectionSet = fieldDetail.node.selectionSet;
if (selectionSet) {
const { deferUsage, fragmentVariables } = fieldDetail;
collectFieldsImpl(
context,
node.selectionSet,
selectionSet,
subGroupedFieldSet,
newDeferUsages,
fieldDetail.deferUsage,
deferUsage,
fragmentVariables,
);
}
}
Expand Down

0 comments on commit db670e9

Please sign in to comment.