plugin-graphql
plugin-graphql copied to clipboard
Forcing upcase on model name in buildQuery overwites value set by adapter
In source file plugin-graphql/blob/master/src/graphql/query-builder.ts, function name buildQuery(...). I don't think this uppcaseFirstLetter(name) should be used here. It appears to be changing a value set by a custom adapter.
// build query const query: string = \
${type} ${upcaseFirstLetter(name)}${this.buildArguments(
model,
args,
true,
filter,
true,
field
)} {\n` +
` ${this.buildField(model, multiple, args, [], name, filter, true)}\n` +
}
;
`
Impacts using a custom adapter to set the name of a mutation with getNameforPersit(model).