@graphql-tools/utils 8.5.0-alpha-dbd8abf5.0 → 8.5.2

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.
Files changed (3) hide show
  1. package/index.js +3 -3
  2. package/index.mjs +3 -3
  3. package/package.json +1 -1
package/index.js CHANGED
@@ -1013,10 +1013,10 @@ function astFromScalarType(type, schema, pathToDirectivesInExtensions) {
1013
1013
  const directives = directivesInExtensions
1014
1014
  ? makeDirectiveNodes(schema, directivesInExtensions)
1015
1015
  : ((_a = type.astNode) === null || _a === void 0 ? void 0 : _a.directives) || [];
1016
- if (type['specifiedByUrl'] &&
1017
- !directives.some(directiveNode => directiveNode.name.value === 'specifiedBy')) {
1016
+ const specifiedByValue = (type['specifiedByUrl'] || type['specifiedByURL']);
1017
+ if (specifiedByValue && !directives.some(directiveNode => directiveNode.name.value === 'specifiedBy')) {
1018
1018
  const specifiedByArgs = {
1019
- url: type['specifiedByUrl'],
1019
+ url: specifiedByValue,
1020
1020
  };
1021
1021
  directives.push(makeDirectiveNode('specifiedBy', specifiedByArgs));
1022
1022
  }
package/index.mjs CHANGED
@@ -1009,10 +1009,10 @@ function astFromScalarType(type, schema, pathToDirectivesInExtensions) {
1009
1009
  const directives = directivesInExtensions
1010
1010
  ? makeDirectiveNodes(schema, directivesInExtensions)
1011
1011
  : ((_a = type.astNode) === null || _a === void 0 ? void 0 : _a.directives) || [];
1012
- if (type['specifiedByUrl'] &&
1013
- !directives.some(directiveNode => directiveNode.name.value === 'specifiedBy')) {
1012
+ const specifiedByValue = (type['specifiedByUrl'] || type['specifiedByURL']);
1013
+ if (specifiedByValue && !directives.some(directiveNode => directiveNode.name.value === 'specifiedBy')) {
1014
1014
  const specifiedByArgs = {
1015
- url: type['specifiedByUrl'],
1015
+ url: specifiedByValue,
1016
1016
  };
1017
1017
  directives.push(makeDirectiveNode('specifiedBy', specifiedByArgs));
1018
1018
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@graphql-tools/utils",
3
- "version": "8.5.0-alpha-dbd8abf5.0",
3
+ "version": "8.5.2",
4
4
  "description": "Common package containing utils and types for GraphQL tools",
5
5
  "sideEffects": false,
6
6
  "peerDependencies": {