Update nullability

If object is nil, which it can be, Swift freaks out, since we'd promised
it would never be nil.

// FREEBIE
pull/1/head
Michael Kirk 7 years ago
parent 4d539ba1c4
commit c926ca10a5

@ -10,7 +10,7 @@ extern NSString *const TSNetworkManagerDomain;
BOOL IsNSErrorNetworkFailure(NSError *_Nullable error);
typedef void (^TSNetworkManagerSuccess)(NSURLSessionDataTask *task, id responseObject);
typedef void (^TSNetworkManagerSuccess)(NSURLSessionDataTask *task, _Nullable id responseObject);
typedef void (^TSNetworkManagerFailure)(NSURLSessionDataTask *task, NSError *error);
@class TSRequest;

@ -71,7 +71,7 @@ typedef void (^failureBlock)(NSURLSessionDataTask *task, NSError *error);
DDLogInfo(@"%@ Making request: %@", self.logTag, request);
// TODO: Remove this logging when the call connection issues have been resolved.
TSNetworkManagerSuccess success = ^(NSURLSessionDataTask *task, id responseObject) {
TSNetworkManagerSuccess success = ^(NSURLSessionDataTask *task, _Nullable id responseObject) {
DDLogInfo(@"%@ request succeeded : %@", self.logTag, request);
successBlock(task, responseObject);
};

Loading…
Cancel
Save