Adding background_ios flag to background fetches.

This commit is contained in:
Samuel Clay 2017-04-04 13:36:20 -07:00
parent 44c6342f1d
commit cb0d567738
2 changed files with 6 additions and 2 deletions

View file

@ -424,6 +424,10 @@ static UIFont *userLabelFont;
self.appDelegate.url];
}
if (appDelegate.backgroundCompletionHandler) {
urlFeedList = [urlFeedList stringByAppendingString:@"&background_ios=true"];
}
[appDelegate.networkManager GET:urlFeedList parameters:nil progress:nil success:^(NSURLSessionDataTask * _Nonnull task, id _Nullable responseObject) {
[self finishLoadingFeedList:responseObject];
} failure:^(NSURLSessionDataTask * _Nullable task, NSError * _Nonnull error) {
@ -433,7 +437,7 @@ static UIFont *userLabelFont;
self.lastUpdate = [NSDate date];
if (showLoader) {
[self.notifier hide];
// [self.notifier hide];
}
[self showRefreshNotifier];
}

View file

@ -8,7 +8,7 @@
#import <MobileCoreServices/MobileCoreServices.h>
//#define DEBUG 1
//#define PROD_DEBUG 1
#define PROD_DEBUG 1
#ifdef DEBUG
#define BACKGROUND_REFRESH_SECONDS -5