ONEAPP-3998: Allow a chance to override code.
This commit is contained in:
parent
53634fcaa1
commit
3383d71c19
@ -371,10 +371,11 @@
|
||||
return;
|
||||
}
|
||||
|
||||
#if TESTING
|
||||
if ([[MVMCoreObject sharedInstance].globalLoadDelegate respondsToSelector:@selector(modifyJSON:)]) {
|
||||
jsonDictionary = [[MVMCoreObject sharedInstance].globalLoadDelegate modifyJSON:jsonDictionary];
|
||||
}
|
||||
|
||||
#endif
|
||||
loadObject.responseJSON = jsonDictionary;
|
||||
|
||||
// Store the new page data if we didn't load page data from the cache.
|
||||
|
||||
@ -16,7 +16,10 @@
|
||||
|
||||
@optional
|
||||
|
||||
#if TESTING
|
||||
/// Allows a chance to modify the json and provide local test json.
|
||||
- (nonnull NSDictionary *)modifyJSON:(nonnull NSDictionary *)json;
|
||||
#endif
|
||||
|
||||
// Provides the desired error screen for the native error. Called on the main thread. If set, any native errors or NSURLErrorDomain errors will use a native screen.
|
||||
- (nullable UIViewController <MVMCoreViewControllerProtocol> *)getNativeScreenForRequestError:(nonnull MVMCoreErrorObject *)errorObject requestObject:(nonnull MVMCoreRequestParameters *)requestObject;
|
||||
@ -43,4 +46,6 @@
|
||||
/// Checks to see if the operation has content to show.
|
||||
- (BOOL)hasContentToShow:(nonnull MVMCoreLoadObject *)loadObject error:(nullable MVMCoreErrorObject *)error;
|
||||
|
||||
- (nonnull NSDictionary *)getJSON:(nonnull NSDictionary *)json;
|
||||
|
||||
@end
|
||||
|
||||
Loading…
Reference in New Issue
Block a user