We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 056a6e4 commit fe4f8ebCopy full SHA for fe4f8eb
src/utilities/buildASTSchema.js
@@ -72,6 +72,14 @@ export function buildASTSchema(
72
assertValidSDL(documentAST);
73
}
74
75
+ const emptySchemaConfig = {
76
+ description: undefined,
77
+ types: [],
78
+ directives: [],
79
+ extensions: undefined,
80
+ extensionASTNodes: [],
81
+ assumeValid: false,
82
+ };
83
const config = extendSchemaImpl(emptySchemaConfig, documentAST, options);
84
85
if (config.astNode == null) {
@@ -114,8 +122,6 @@ export function buildASTSchema(
114
122
return new GraphQLSchema(config);
115
123
116
124
117
-const emptySchemaConfig = new GraphQLSchema({ directives: [] }).toConfig();
118
-
119
125
/**
120
126
* A helper function to build a GraphQLSchema directly from a source
121
127
* document.
0 commit comments