Removed check for pageType for App level , making it generic on cachePolicy.
This commit is contained in:
parent
40106d3a9c
commit
161cc0132d
@ -141,7 +141,6 @@ extension PersistentCacheManager {
|
|||||||
guard let cachePolicy = infoDictionary[KeyCachePolicy] as? Dictionary<String, Any>,
|
guard let cachePolicy = infoDictionary[KeyCachePolicy] as? Dictionary<String, Any>,
|
||||||
let appLevelKey = cachePolicy[KeyAppLevelCachePolicy] as? Bool,
|
let appLevelKey = cachePolicy[KeyAppLevelCachePolicy] as? Bool,
|
||||||
appLevelKey == true,
|
appLevelKey == true,
|
||||||
self.shouldCachePageJSON(infoDictionary, pageType: PageTypeOfflineFeedback) == true,
|
|
||||||
self.isJSONExpired(infoDictionary) == false else {return false}
|
self.isJSONExpired(infoDictionary) == false else {return false}
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|||||||
@ -15,7 +15,7 @@
|
|||||||
extern NSString * _Nonnull const KeyCachePolicy;
|
extern NSString * _Nonnull const KeyCachePolicy;
|
||||||
extern NSString * _Nonnull const KeyCacheExpiry;
|
extern NSString * _Nonnull const KeyCacheExpiry;
|
||||||
extern NSString * _Nonnull const KeyAppLevelCachePolicy;
|
extern NSString * _Nonnull const KeyAppLevelCachePolicy;
|
||||||
extern NSString * _Nonnull const PageTypeOfflineFeedback;
|
|
||||||
|
|
||||||
|
|
||||||
//block returned when getting image
|
//block returned when getting image
|
||||||
|
|||||||
@ -20,7 +20,7 @@
|
|||||||
NSString * _Nonnull const KeyCachePolicy = @"cachePolicy";
|
NSString * _Nonnull const KeyCachePolicy = @"cachePolicy";
|
||||||
NSString * _Nonnull const KeyCacheExpiry = @"expiry";
|
NSString * _Nonnull const KeyCacheExpiry = @"expiry";
|
||||||
NSString * _Nonnull const KeyAppLevelCachePolicy = @"applicationLevelCache";
|
NSString * _Nonnull const KeyAppLevelCachePolicy = @"applicationLevelCache";
|
||||||
NSString * _Nonnull const PageTypeOfflineFeedback = @"offlineFeedback";
|
|
||||||
|
|
||||||
|
|
||||||
@interface MVMCoreCache ()
|
@interface MVMCoreCache ()
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user