@@ -946,15 +946,15 @@ function completeAbstractValue(
946
946
947
947
if ( isThenable ( runtimeType ) ) {
948
948
// Cast to Promise
949
- const runtimeTypePromise : Promise < GraphQLObjectType | string > =
949
+ const runtimeTypePromise : Promise < ? GraphQLObjectType | string > =
950
950
( runtimeType : any ) ;
951
951
return runtimeTypePromise . then ( resolvedRuntimeType =>
952
952
completeObjectValue (
953
953
exeContext ,
954
954
ensureValidRuntimeType (
955
955
resolvedRuntimeType ,
956
- exeContext ,
957
- returnType ,
956
+ exeContext ,
957
+ returnType ,
958
958
fieldNodes ,
959
959
info ,
960
960
result
@@ -970,9 +970,9 @@ function completeAbstractValue(
970
970
return completeObjectValue (
971
971
exeContext ,
972
972
ensureValidRuntimeType (
973
- resolvedRuntimeType ,
973
+ ( ( runtimeType : any ) : ? GraphQLObjectType | string ) ,
974
974
exeContext ,
975
- returnType ,
975
+ returnType ,
976
976
fieldNodes ,
977
977
info ,
978
978
result
@@ -985,15 +985,15 @@ function completeAbstractValue(
985
985
}
986
986
987
987
function ensureValidRuntimeType(
988
- runtimeTypeOrName: string | GraphQLObjectType | void ,
988
+ runtimeTypeOrName: ? GraphQLObjectType | string ,
989
989
exeContext: ExecutionContext,
990
990
returnType: GraphQLAbstractType,
991
991
fieldNodes: Array< FieldNode > ,
992
992
info: GraphQLResolveInfo,
993
993
result: mixed
994
994
): GraphQLObjectType {
995
- const runtimeType = typeof runtimeTypeOrName === 'string' ?
996
- exeContext . schema . getType ( runtimeTypeOrName ) :
995
+ const runtimeType = typeof runtimeTypeOrName === 'string' ?
996
+ exeContext . schema . getType ( runtimeTypeOrName ) :
997
997
runtimeTypeOrName ;
998
998
999
999
if ( ! ( runtimeType instanceof GraphQLObjectType ) ) {
0 commit comments