1
This commit is contained in:
@@ -53,7 +53,7 @@
|
||||
// }
|
||||
return;
|
||||
}
|
||||
|
||||
[KBHUD dismiss];
|
||||
id dataObj = json[KBData] ?: json[@"data"];
|
||||
if (![dataObj isKindOfClass:[NSArray class]]) {
|
||||
NSError *e = [NSError errorWithDomain:KBNetworkErrorDomain
|
||||
@@ -92,9 +92,9 @@
|
||||
- (void)fetchRankListByTagParams:(NSDictionary *)params
|
||||
needShow:(BOOL)needShow
|
||||
completion:(KBHomeRankCompletion)completion {
|
||||
if (needShow) {
|
||||
[KBHUD show];
|
||||
}
|
||||
// if (needShow) {
|
||||
// [KBHUD show];
|
||||
// }
|
||||
NSString *loginUrl = @"";
|
||||
if ([KBUserSessionManager shared].isLoggedIn) {
|
||||
loginUrl = API_CHARACTER_LIST_BY_TAG;
|
||||
@@ -106,9 +106,10 @@
|
||||
headers:nil
|
||||
autoShowBusinessError:NO
|
||||
completion:^(NSDictionary * _Nullable json, NSURLResponse * _Nullable response, NSError * _Nullable error) {
|
||||
if (needShow) {
|
||||
// if (needShow) {
|
||||
// [KBHUD dismiss];
|
||||
// }
|
||||
[KBHUD dismiss];
|
||||
}
|
||||
|
||||
if (error) {
|
||||
NSString *msg = KBBizMessageFromJSONObject(json) ?: error.localizedDescription ?: KBLocalized(@"Network error");
|
||||
|
||||
@@ -462,7 +462,6 @@ autoShowBusinessError:YES
|
||||
return;
|
||||
}
|
||||
// code 缺失或为成功,按正常成功回调
|
||||
[KBHUD dismiss];
|
||||
if (completion) completion(dict, response, nil);
|
||||
} else {
|
||||
// 预期 JSON,但未检测到 JSON 内容
|
||||
|
||||
Reference in New Issue
Block a user