Skip to content

Commit

Permalink
chore: explained persisted call expression
Browse files Browse the repository at this point in the history
  • Loading branch information
felamaslen committed Jun 11, 2024
1 parent b4d4d33 commit 63bebeb
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/graphqlsp/src/ast/checks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,8 @@ export const getSchemaName = (
): string | null => {
if (!typeChecker) return null;
const type = typeChecker.getTypeAtLocation(
// When calling `graphql.persisted`, we need to access the `graphql` part of
// the expression; `node.expression` is the `.persisted` part
isTadaPersistedCall ? node.getChildAt(0).getChildAt(0) : node.expression
);
if (type) {
Expand Down

0 comments on commit 63bebeb

Please sign in to comment.