File tree Expand file tree Collapse file tree 2 files changed +2
-3
lines changed
src/main/kotlin/com/coxautodev/graphql/tools Expand file tree Collapse file tree 2 files changed +2
-3
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ import graphql.language.TypeName
1313import graphql.schema.DataFetcher
1414import graphql.schema.DataFetchingEnvironment
1515import graphql.schema.GraphQLTypeUtil.*
16- import kotlinx.coroutines.GlobalScope
1716import kotlinx.coroutines.future.future
1817import java.lang.reflect.Method
1918import java.util.Comparator
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ import graphql.language.ObjectTypeExtensionDefinition
88import graphql.language.Type
99import graphql.schema.DataFetchingEnvironment
1010import kotlinx.coroutines.CoroutineScope
11- import kotlinx.coroutines.GlobalScope
11+ import kotlinx.coroutines.Dispatchers
1212import java.lang.reflect.Method
1313import java.lang.reflect.ParameterizedType
1414import java.lang.reflect.Proxy
@@ -44,7 +44,7 @@ internal fun JavaType.unwrap(): Class<out Any> =
4444
4545internal fun DataFetchingEnvironment.coroutineScope (): CoroutineScope {
4646 val context: Any? = this .getContext()
47- return if (context is CoroutineScope ) context else GlobalScope
47+ return if (context is CoroutineScope ) context else CoroutineScope ( Dispatchers . Default )
4848}
4949
5050internal val Class <* >.declaredNonProxyMethods: List <JavaMethod >
You can’t perform that action at this time.
0 commit comments