You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit cb662e5
Browse filesBrowse the repository at this point in the historyBrowse files
Move the unexpected-type error messages out of SchemaParser
Moves unexpectedTypeError, unreachedTypeHint, findUsage and fieldUsages to
TypeReferenceErrors.kt. determineType stays in SchemaParser, because for input
types it builds missing input objects through createInputObject.
Edits to compile:
- TypeReferenceErrors' header, with definitions, unusedDefinitions and
typeExtensions.
- private dropped on unexpectedTypeError.
- SchemaParser holds a typeReferenceErrors, and determineType throws through
it.
- Imports.
"Return it from a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes."
681
-
isEnumTypeDefinition->
682
-
"Use it in a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes and pass its enum class in the parser's dictionary."
683
-
isInputObjectTypeDefinition->
684
-
"Use it in an argument of a resolver method, directly or through another input type. SchemaParserOptions.includeUnusedTypes doesn't include input types."
685
-
isScalarTypeDefinition->
686
-
"Use it in a resolver method or one of those classes. SchemaParserOptions.includeUnusedTypes doesn't include scalars."
687
-
else->
688
-
"Return it from a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes and pass a class for it in the parser's dictionary."
689
-
}
690
-
691
-
// determineType only gets the type reference, so the definition using it is looked up for the error message
"Return it from a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes."
44
+
isEnumTypeDefinition->
45
+
"Use it in a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes and pass its enum class in the parser's dictionary."
46
+
isInputObjectTypeDefinition->
47
+
"Use it in an argument of a resolver method, directly or through another input type. SchemaParserOptions.includeUnusedTypes doesn't include input types."
48
+
isScalarTypeDefinition->
49
+
"Use it in a resolver method or one of those classes. SchemaParserOptions.includeUnusedTypes doesn't include scalars."
50
+
else->
51
+
"Return it from a resolver method or one of those classes, or set SchemaParserOptions.includeUnusedTypes and pass a class for it in the parser's dictionary."
52
+
}
53
+
54
+
// determineType only gets the type reference, so the definition using it is looked up for the error message
0 commit comments