Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
return ObjectTypeComposer.createTemp(options, schemaComposer)
}
case CreatedGraphQLType.Union:
return UnionTypeComposer.createTemp(options, schemaComposer)
case CreatedGraphQLType.Input:
return InputTypeComposer.createTemp(options, schemaComposer)
case CreatedGraphQLType.Scalar:
return ScalarTypeComposer.createTemp(options, schemaComposer)
case CreatedGraphQLType.Interface:
return InterfaceTypeComposer.createTemp(options, schemaComposer)
case CreatedGraphQLType.Enum:
return EnumTypeComposer.createTemp(options, schemaComposer)
}
}
result.false_boolean = { value: false };
} else if (val === 'null') {
result.null_string = { value: 'null' };
} else if (Number.isFinite(val)) {
result[`number_${(val: any)}`] = { value: val };
} else if (typeof val === 'string') {
result[val] = { value: val };
}
return result;
}, {});
let postfix = Object.keys(this.cachedEnums[key]).length;
if (postfix === 0) postfix = '';
else postfix = `_${postfix}`;
this.cachedEnums[key][subKey] = EnumTypeComposer.createTemp({
name: `${this.prefix}Enum_${upperFirst(fieldName)}${postfix}`,
values,
});
}
return this.cachedEnums[key][subKey];
}