@graphql-tools/delegate 7.0.8-alpha-f9bebbe6.0 → 7.0.8
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.
- package/es5/index.cjs.js +7 -2
- package/es5/index.cjs.js.map +1 -1
- package/es5/index.esm.js +7 -2
- package/es5/index.esm.js.map +1 -1
- package/es5/package.json +9 -5
- package/es5/types.d.ts +1 -0
- package/index.cjs.js +7 -2
- package/index.cjs.js.map +1 -1
- package/index.esm.js +7 -2
- package/index.esm.js.map +1 -1
- package/package.json +9 -5
- package/types.d.ts +1 -0
package/es5/index.esm.js
CHANGED
|
@@ -640,8 +640,13 @@ function resolveExternalValue(result, unpathedErrors, subschema, context, info,
|
|
|
640
640
|
}
|
|
641
641
|
function resolveExternalObject(type, object, unpathedErrors, subschema, context, info, skipTypeMerging) {
|
|
642
642
|
var _a;
|
|
643
|
-
|
|
643
|
+
// if we have already resolved this object, for example, when the identical object appears twice
|
|
644
|
+
// in a list, see https://github.com/ardatan/graphql-tools/issues/2304
|
|
645
|
+
if (isExternalObject(object)) {
|
|
646
|
+
return object;
|
|
647
|
+
}
|
|
644
648
|
annotateExternalObject(object, unpathedErrors, subschema);
|
|
649
|
+
var stitchingInfo = (_a = info === null || info === void 0 ? void 0 : info.schema.extensions) === null || _a === void 0 ? void 0 : _a.stitchingInfo;
|
|
645
650
|
if (skipTypeMerging || !stitchingInfo) {
|
|
646
651
|
return object;
|
|
647
652
|
}
|
|
@@ -1533,7 +1538,7 @@ function defaultDelegationBinding(delegationContext) {
|
|
|
1533
1538
|
if (stitchingInfo != null) {
|
|
1534
1539
|
delegationTransforms = delegationTransforms.concat([
|
|
1535
1540
|
new ExpandAbstractTypes(),
|
|
1536
|
-
new AddSelectionSets(
|
|
1541
|
+
new AddSelectionSets(stitchingInfo.selectionSetsByType, stitchingInfo.selectionSetsByField, stitchingInfo.dynamicSelectionSetsByField),
|
|
1537
1542
|
new WrapConcreteTypes(),
|
|
1538
1543
|
]);
|
|
1539
1544
|
}
|