Skip to content

Commit

Permalink
diffQueryAgainsStore set returnPartialData to false
Browse files Browse the repository at this point in the history
Is there a reason why returnPartialData is true?
This was hiding an error and returning { data: undefined, networkState: 7, stale: true } for me.
I had forgotten to query for the id of an object and watchQuery could not find it in store.
With returnPartialData false i was able to get an error about missing property and finally find the problem.
With this true all i was getting from watchQuery was { data: undefined, networkState: 7, stale: true }.

Maybe related issues: apollographql#3030 , apollographql#2914
  • Loading branch information
quazzie authored Oct 24, 2018
1 parent 18dfe93 commit 394a1e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/apollo-cache-inmemory/src/readFromStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ export class StoreReader {
query,
variables,
previousResult,
returnPartialData = true,
returnPartialData = false,
rootId = 'ROOT_QUERY',
fragmentMatcherFunction,
config,
Expand Down

0 comments on commit 394a1e4

Please sign in to comment.