Skip to content

Commit

Permalink
Update ValidationMiddlewares.cs (#98)
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeyshaykhullin authored Apr 6, 2022
1 parent cad5e2b commit 88a2989
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/ValidationMiddlewares.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ public static FieldDelegate Field(FieldDelegate next)
{
return async middlewareContext =>
{
var argumentNodes = middlewareContext.Selection.SyntaxNode.Arguments;

if (argumentNodes is { Count: > 0 })
if (middlewareContext.Selection.SyntaxNode.Arguments is { Count: > 0 } argumentNodes)
{
var objectFieldOptions = middlewareContext.Selection.Field.ContextData.GetObjectFieldOptions();

Expand Down

0 comments on commit 88a2989

Please sign in to comment.