fix incorrect enum-value type names for enums used as inputs

luckily webapp is now a much more complete test suite and genqlient's
own tests, so it caught this!
This commit is contained in:
Ben Kraft
2021-04-21 17:41:33 -07:00
parent 9bc97108ea
commit 32fea7fae4
5 changed files with 64 additions and 1 deletions
+1 -1
View File
@@ -372,7 +372,7 @@ func (builder *typeBuilder) writeTypedef(
builder.WriteString("const (\n")
for _, val := range typedef.EnumValues {
fmt.Fprintf(builder, "%s %s = \"%s\"\n",
typeNamePrefix+goConstName(val.Name),
typeName+goConstName(val.Name),
typeName, val.Name)
}
builder.WriteString(")\n")