You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When it goes to cacheResultProcessor.processReadResult and here you obtain fieldName (allMeters in my case) and resultKeyName (meters in my case) and then pass fieldName to processReadSubResult function
The first thing processReadSubResult does is extracting field from result. So in my case it tries to get result['allMeters'], which resolved in undefined and processReadSubResult returns Completed status.
I propose to fix this by passing in processReadSubResult in step 2 value like so resultKeyName || fieldName.
What do you think?
The text was updated successfully, but these errors were encountered:
Hi, thanks for such a useful library for Apollo-client. Recently I decided to apply it to my project and found the following error:
If you use alias for query, the cache will not be invalidated:
I've started digging into why this was happening and discovered the following:
super.diff
right here it returns result in format like so (aliases as keys):cacheResultProcessor.processReadResult
and here you obtainfieldName
(allMeters
in my case) andresultKeyName
(meters
in my case) and then pass fieldName toprocessReadSubResult
functionprocessReadSubResult
does is extracting field from result. So in my case it tries to getresult['allMeters']
, which resolved inundefined
andprocessReadSubResult
returnsCompleted
status.I propose to fix this by passing in
processReadSubResult
in step 2 value like soresultKeyName || fieldName
.What do you think?
The text was updated successfully, but these errors were encountered: