From 2c734713318bc97ed8edb3c26d2de07f40f3d998 Mon Sep 17 00:00:00 2001 From: Daniel Rearden Date: Sat, 27 Jun 2020 15:25:28 -0400 Subject: [PATCH] Fix RequestInfo typings --- src/index.d.ts | 6 +++--- src/index.js | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/index.d.ts b/src/index.d.ts index d873892f..d31e3b11 100644 --- a/src/index.d.ts +++ b/src/index.d.ts @@ -153,17 +153,17 @@ export interface RequestInfo { /** * The variable values used at runtime. */ - variables: { readonly [name: string]: unknown }; + variables: { readonly [name: string]: unknown } | null; /** * The (optional) operation name requested. */ - operationName: string; + operationName: string | null; /** * The result of executing the operation. */ - result: unknown; + result: ExecutionResult; /** * A value to pass as the context to the graphql() function. diff --git a/src/index.js b/src/index.js index 8cd5631e..1fa8c290 100644 --- a/src/index.js +++ b/src/index.js @@ -171,7 +171,7 @@ export type RequestInfo = {| /** * The result of executing the operation. */ - result: ExecutionResult | null, + result: ExecutionResult, /** * A value to pass as the context to the graphql() function.