From 0adaed3a786e6c98a68c19cffd1dcb5f023c148a Mon Sep 17 00:00:00 2001 From: Will Johnston Date: Mon, 13 Sep 2021 10:23:54 -0700 Subject: [PATCH] fix: revision typings are using proper maybe checks (#452) * fix: revision typings are using proper maybe checks * fix: lint --- packages/react/src/client.ts | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/packages/react/src/client.ts b/packages/react/src/client.ts index cf6e9bad8..e64912c0a 100644 --- a/packages/react/src/client.ts +++ b/packages/react/src/client.ts @@ -2,6 +2,7 @@ import { CategoryIdType, ClientConfig, getClient as getCoreClient, + Maybe, PageIdType, PostIdType, } from '@faustjs/core'; @@ -19,9 +20,13 @@ export interface Node { } export interface WithRevisions { - revisions: (arg0: { first: number }) => { - edges?: { node?: Node }[]; - }; + revisions: (arg0: { first?: number }) => Maybe<{ + edges?: Maybe< + Maybe<{ + node?: Maybe; + }>[] + >; + }>; } export interface RequiredQuery {