Commit e682b742 by Dima Bart

Remove explicit network queue, make request queue private.

parent 1c96e165
...@@ -96,11 +96,6 @@ NS_ASSUME_NONNULL_BEGIN ...@@ -96,11 +96,6 @@ NS_ASSUME_NONNULL_BEGIN
@property (nonatomic, strong, nonnull) BUYModelManager *modelManager; @property (nonatomic, strong, nonnull) BUYModelManager *modelManager;
/** /**
* Queue on which all request operation are executed
*/
@property (nonatomic, strong, readonly, nonnull) NSOperationQueue *requestQueue;
/**
* Queue on which network completion callbacks will be executed * Queue on which network completion callbacks will be executed
*/ */
@property (nonatomic, strong, nonnull) NSOperationQueue *callbackQueue; @property (nonatomic, strong, nonnull) NSOperationQueue *callbackQueue;
......
...@@ -34,7 +34,7 @@ static NSString * const BUYClientJSONMimeType = @"application/json"; ...@@ -34,7 +34,7 @@ static NSString * const BUYClientJSONMimeType = @"application/json";
@interface BUYClient () <NSURLSessionDelegate> @interface BUYClient () <NSURLSessionDelegate>
@property (nonatomic, strong) NSURLSession *session; @property (nonatomic, strong) NSURLSession *session;
@property (nonatomic, strong) NSOperationQueue *networkQueue; @property (nonatomic, strong) NSOperationQueue *requestQueue;
@end @end
...@@ -62,7 +62,6 @@ static NSString * const BUYClientJSONMimeType = @"application/json"; ...@@ -62,7 +62,6 @@ static NSString * const BUYClientJSONMimeType = @"application/json";
_callbackQueue = [NSOperationQueue mainQueue]; _callbackQueue = [NSOperationQueue mainQueue];
_requestQueue = [NSOperationQueue new]; _requestQueue = [NSOperationQueue new];
_networkQueue = [NSOperationQueue new];
_session = [self urlSession]; _session = [self urlSession];
_pageSize = 25; _pageSize = 25;
...@@ -96,7 +95,7 @@ static NSString * const BUYClientJSONMimeType = @"application/json"; ...@@ -96,7 +95,7 @@ static NSString * const BUYClientJSONMimeType = @"application/json";
NSURLSessionConfiguration *config = [NSURLSessionConfiguration defaultSessionConfiguration]; NSURLSessionConfiguration *config = [NSURLSessionConfiguration defaultSessionConfiguration];
config.HTTPAdditionalHeaders = [self additionalHeaders]; config.HTTPAdditionalHeaders = [self additionalHeaders];
return [NSURLSession sessionWithConfiguration:config delegate:self delegateQueue:self.networkQueue]; return [NSURLSession sessionWithConfiguration:config delegate:self delegateQueue:nil];
} }
- (void)setPageSize:(NSUInteger)pageSize - (void)setPageSize:(NSUInteger)pageSize
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment