Given this type:
type Test {
test1: [String]
test2: [String!]
test3: [String]!
test4: [String!]!
}
I'd expect returning nil in each resolver to produce:
{
"data": {
"test": {
"test1": null,
"test2": null,
"test3": [],
"test4": []
}
}
}
This is what's returned instead:
{
"data": {
"test": {
"test1": [],
"test2": [],
"test3": [],
"test4": []
}
}
}
https://github.com/facebook/graphql/issues/171 for context.
Is this an error or by design? Thanks in advance.
Looks like a bug. Go treats nils like empty arrays so it would be an easy one to make.
Same problem here! Any update about it? :disappointed: