Why am I getting previous result, if I use KCSCachePolicyLocalFirst?
P
Pavel Vilbik
started a topic
almost 6 years ago
GIVEN:
I have configured KCSLinkedAppdataStore the following way:
KCSCollection *collectionQuote = [KCSCollection collectionFromString:QUOTES_COLLECTIONS_NAME
ofClass:[Quote class]];
self.quotesStore = [KCSLinkedAppdataStore storeWithOptions:@{ KCSStoreKeyResource :collectionQuote, KCSStoreKeyCachePolicy : @(KCSCachePolicyNetworkFirst)}];
STEPS:
1. Call queryWithQuery:withCompletionBlock:withProgressBlock:cachePolicy: method with cache policy KCSCachePolicyLocalFirst and with query1.
2. Call queryWithQuery:withCompletionBlock:withProgressBlock:cachePolicy: method with cache policy KCSCachePolicyLocalFirst and with query2.
Expected result: in step #2 we receive data that corresponds to query2 conditions.
Actual result: in step #2 we receive data that corresponds to query1 conditions.
PS. Completion block is called only once in both steps.
1 Comment
Damien Bell
said
almost 6 years ago
Good morning Pavel,
Could you send me over the code in these queries? Without the code that you used to reproduce this issue at this time.
damien@kinvey.com is my email address.
Thanks,
Pavel Vilbik