Skip to content

Commit

Permalink
Update cache-configuration.mdx
Browse files Browse the repository at this point in the history
  • Loading branch information
smyrick authored Apr 22, 2024
1 parent 24a611c commit d0516a8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/source/caching/cache-configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ const cache = new InMemoryCache({
// You can also use a function to determine any of the values above.
// The first argument is the reference to the record to be written, and the second is the runtime context
keyFields: (location, context) => {
if (context.storeObject.location.state) {
if (context.readField("location", context.readField("state"))) {
return ["city, "state", "country"];
} else {
return ["city, "country"];
Expand Down

0 comments on commit d0516a8

Please sign in to comment.