@coderich/autograph 0.13.16 → 0.13.17

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@coderich/autograph",
3
3
  "main": "index.js",
4
- "version": "0.13.16",
4
+ "version": "0.13.17",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -176,11 +176,11 @@ module.exports = class Schema {
176
176
  }
177
177
 
178
178
  if (node.kind === Kind.NON_NULL_TYPE) {
179
- field[isList ? 'isArrayRequired' : 'isRequired'] = true;
179
+ target[isList ? 'isArrayRequired' : 'isRequired'] = true;
180
180
  } else if (node.kind === Kind.NAMED_TYPE) {
181
- field.type = node.name.value;
181
+ target.type = node.name.value;
182
182
  } else if (node.kind === Kind.LIST_TYPE) {
183
- field.isArray = true;
183
+ target.isArray = true;
184
184
  isList = true;
185
185
  } else if (node.kind === Kind.DIRECTIVE) {
186
186
  target.directives[name] = target.directives[name] || {};
@@ -215,11 +215,11 @@ module.exports = class Schema {
215
215
  }
216
216
  // Field specific directives
217
217
  case `${directives.field}-default`: {
218
- field.defaultValue = value;
218
+ target.defaultValue = value;
219
219
  break;
220
220
  }
221
221
  case `${directives.field}-connection`: {
222
- field.isConnection = value;
222
+ target.isConnection = value;
223
223
  break;
224
224
  }
225
225
  case `${directives.field}-validate`: { // Alias for finalize
@@ -227,8 +227,8 @@ module.exports = class Schema {
227
227
  break;
228
228
  }
229
229
  case `${directives.link}-by`: {
230
- field.linkBy = value;
231
- field.isVirtual = true;
230
+ target.linkBy = value;
231
+ target.isVirtual = true;
232
232
  break;
233
233
  }
234
234
  // Generic by target directives
@@ -248,7 +248,7 @@ module.exports = class Schema {
248
248
  // Backwards compat (deprecated)
249
249
  case 'model-gqlScope': { model.crud = value; break; }
250
250
  case 'model-fieldScope': { model.scope = value; break; }
251
- case 'field-gqlScope': { field.crud = value; break; }
251
+ case 'field-gqlScope': { target.crud = value; break; }
252
252
 
253
253
  // Pipelines
254
254
  default: {