Skip to content

Commit

Permalink
Use early return when there is no fieldDef
Browse files Browse the repository at this point in the history
  • Loading branch information
rachsmithcodes committed May 24, 2022
1 parent 1b91ab4 commit 78e9cc4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/language-server/errors/validation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ export function NoMissingClientDirectives(context: ValidationContext) {
const fieldDef = context.getFieldDef();

// if we don't have a type to check then we can early return
if (!parentType) return;
if (!parentType || fieldDef) return;

// here we collect all of the fields on a type that are marked "local"
const clientFields =
Expand Down

0 comments on commit 78e9cc4

Please sign in to comment.