@graphql-tools/delegate 9.0.20 → 9.0.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -260,7 +260,7 @@ function getExpandedFragments(fragments, fragmentNames, possibleTypesMap) {
|
|
|
260
260
|
}
|
|
261
261
|
function wrapConcreteTypes(returnType, targetSchema, document) {
|
|
262
262
|
const namedType = (0, graphql_1.getNamedType)(returnType);
|
|
263
|
-
if (!(0, graphql_1.
|
|
263
|
+
if (!(0, graphql_1.isCompositeType)(namedType)) {
|
|
264
264
|
return document;
|
|
265
265
|
}
|
|
266
266
|
const rootTypeNames = (0, utils_1.getRootTypeNames)(targetSchema);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Kind, TypeInfo, getNamedType, isAbstractType, isInterfaceType, visit, visitWithTypeInfo,
|
|
1
|
+
import { Kind, TypeInfo, getNamedType, isAbstractType, isInterfaceType, visit, visitWithTypeInfo, isCompositeType, } from 'graphql';
|
|
2
2
|
import { implementsAbstractType, getRootTypeNames, memoize2 } from '@graphql-tools/utils';
|
|
3
3
|
import { getDocumentMetadata } from './getDocumentMetadata.js';
|
|
4
4
|
export function prepareGatewayDocument(originalDocument, transformedSchema, returnType, infoSchema) {
|
|
@@ -256,7 +256,7 @@ function getExpandedFragments(fragments, fragmentNames, possibleTypesMap) {
|
|
|
256
256
|
}
|
|
257
257
|
function wrapConcreteTypes(returnType, targetSchema, document) {
|
|
258
258
|
const namedType = getNamedType(returnType);
|
|
259
|
-
if (!
|
|
259
|
+
if (!isCompositeType(namedType)) {
|
|
260
260
|
return document;
|
|
261
261
|
}
|
|
262
262
|
const rootTypeNames = getRootTypeNames(targetSchema);
|