From 51952fb51be8a2c1a7a68736c90e537507ac2a21 Mon Sep 17 00:00:00 2001 From: Rodolphe Marques Date: Tue, 11 Jan 2022 13:54:04 +0100 Subject: [PATCH] Make types non-nullable by default --- src/codegen/schema.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/codegen/schema.js b/src/codegen/schema.js index 9a0e0ead6..deb6b8fe3 100644 --- a/src/codegen/schema.js +++ b/src/codegen/schema.js @@ -236,7 +236,7 @@ Suggestion: add an '!' to the member type of the List, change from '${fieldValue : gqlType.getIn(['name', 'value']) } - _typeFromGraphQl(gqlType, nullable = true) { + _typeFromGraphQl(gqlType, nullable = false) { if (gqlType.get('kind') === 'NonNullType') { return this._typeFromGraphQl(gqlType.get('type'), false) } else if (gqlType.get('kind') === 'ListType') {