apollo-client: Getting "Can't find field" errors on null fields (even if the field is nullable)
Since 0.4.16.
Once a mutation comes back and its results are reinjected into the store via updateQueries
Can't find field cursor on result object $ROOT_QUERY.connection({"id":"xxx"}).nodeChildren({"id":"root","limit":40,"cursor":null,"sortBy":null}).
Error
at new ApolloError (webpack:///./~/apollo-client/lib/src/errors.js?:14:22)
at eval (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:59:23)
at Array.forEach (native)
at writeSelectionSetToStore (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:53:29)
at eval (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:121:21)
at Array.forEach (native)
at writeSelectionSetToStore (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:53:29)
at writeFieldToStore (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:226:9)
at eval (webpack:///./~/apollo-client/lib/src/data/writeToStore.js?:75:17)
at Array.forEach (native)
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 1
- Comments: 18 (17 by maintainers)
Commits related to this issue
- Trying to reproduce #678 didn't work... — committed to apollographql/apollo-client by rricard 8 years ago
But, yes, I think this PR, even if it’ll help us a lot may be the one responsible