@snowtop/ent 0.1.3 → 0.1.4
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/graphql/graphql.js +4 -1
- package/package.json +1 -1
package/graphql/graphql.js
CHANGED
|
@@ -463,6 +463,9 @@ class GQLCapture {
|
|
|
463
463
|
let baseArgs = new Map();
|
|
464
464
|
this.customArgs.forEach((_val, key) => baseArgs.set(key, true));
|
|
465
465
|
this.customInputObjects.forEach((_val, key) => baseArgs.set(key, true));
|
|
466
|
+
// add all objects as arg types because it can include enums
|
|
467
|
+
// depend on graphql to throw error if it's not a valid input type
|
|
468
|
+
objects.map((object) => baseArgs.set(object, true));
|
|
466
469
|
baseArgs.set("Context", true);
|
|
467
470
|
this.customTypes.forEach((_val, key) => baseArgs.set(key, true));
|
|
468
471
|
this.customUnions.forEach((val, key) => {
|
|
@@ -485,7 +488,7 @@ class GQLCapture {
|
|
|
485
488
|
arg.needsResolving = false;
|
|
486
489
|
}
|
|
487
490
|
else {
|
|
488
|
-
throw new Error(`arg ${arg.name} of field ${field.functionName} needs resolving. should not be possible`);
|
|
491
|
+
throw new Error(`arg ${arg.name} of field ${field.functionName} with type ${arg.type} needs resolving. should not be possible`);
|
|
489
492
|
}
|
|
490
493
|
}
|
|
491
494
|
});
|