Skip to content

Commit

Permalink
Wrap alwaysFetch around unthunk
Browse files Browse the repository at this point in the history
Allow dynamically generating an alwaysFetch clause
  • Loading branch information
GlennMatthys committed Jul 3, 2019
1 parent 7c2122c commit 26e28a2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/query-ast-to-sql-ast/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@ function handleTable(sqlASTNode, queryASTNode, field, gqlType, namespace, grabMa

if (config.alwaysFetch) {
for (let column of wrap(config.alwaysFetch)) {
children.push(columnToASTChild(column, namespace))
children.push(columnToASTChild(unthunk(column, sqlASTNode.as, sqlASTNode.args || {}, context, sqlASTNode), namespace))
}
}

Expand Down

0 comments on commit 26e28a2

Please sign in to comment.