fail逻辑 test
parent
59d54b8a55
commit
38fae22243
|
@ -29,16 +29,22 @@
|
|||
return;
|
||||
}
|
||||
// 再判断回调是否为失败
|
||||
BOOL hasError = [[result allKeys] containsObject:@"errMsg"];
|
||||
// BOOL hasError = [[result allKeys] containsObject:@"errMsg"];
|
||||
// if (hasError) {
|
||||
// NSString *errMsg = result[@"errMsg"];
|
||||
// NSString *errPrefix = [NSString stringWithFormat:@"%@:fail", name];
|
||||
// BOOL isFail = [errMsg hasPrefix:errPrefix];
|
||||
// if (isFail) {
|
||||
// NSLog(@"extensionApi reslut:fail");
|
||||
// callback(FATExtensionCodeFailure,nil);
|
||||
// return;
|
||||
// }
|
||||
// }
|
||||
|
||||
BOOL hasError = [[result allKeys] containsObject:@"phizErr"];
|
||||
if (hasError) {
|
||||
NSString *errMsg = result[@"errMsg"];
|
||||
NSString *errPrefix = [NSString stringWithFormat:@"%@:fail", name];
|
||||
BOOL isFail = [errMsg hasPrefix:errPrefix];
|
||||
if (isFail) {
|
||||
NSLog(@"extensionApi reslut:fail");
|
||||
callback(FATExtensionCodeFailure,nil);
|
||||
return;
|
||||
}
|
||||
callback(FATExtensionCodeFailure,result[@"phizErr"]);
|
||||
return;
|
||||
}
|
||||
// 其他的按成功处理
|
||||
NSLog(@"extensionApi callback:%@",result);
|
||||
|
|
Loading…
Reference in New Issue