Skip to content

Commit 181a937

Browse files
committed
DictionaryResolverType should use GraphQLObjectType from schema rather than cache.
1 parent 9cdf372 commit 181a937

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/kotlin/graphql/kickstart/tools/DictionaryTypeResolver.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ internal abstract class DictionaryTypeResolver(
2525
override fun getType(env: TypeResolutionEnvironment): GraphQLObjectType? {
2626
val clazz = env.getObject<Any>().javaClass
2727
val name = getTypeDefinition(clazz)?.name ?: clazz.simpleName
28-
return types[name] ?: throw TypeResolverError(getError(name))
28+
return env.schema.getObjectType(name) ?: throw TypeResolverError(getError(name))
2929
}
3030

3131
abstract fun getError(name: String): String

0 commit comments

Comments
 (0)