iOS12发布之后审核被拒Guideline 2.5.1

Guideline 2.5.1 - Performance - Software Requirements

Your app uses the "prefs:root=" non-public URL scheme, which is a private entity. The use of non-public APIs is not permitted on the App Store because it can lead to a poor user experience should these APIs change.

Continuing to use or conceal non-public APIs in future submissions of this app may result in the termination of your Apple Developer account, as well as removal of all associated apps from the App Store.

Next Steps

To resolve this issue, please revise your app to provide the associated functionality using public APIs or remove the functionality using the "prefs:root" or "App-Prefs:root" URL scheme.

If there are no alternatives for providing the functionality your app requires, you can file an enhancement request.

app里面代码调用了私有库

在工程中搜索“prefs:root”找到相应的代码

类似

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Photos"]];

替换成

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:UIApplicationOpenSettingsURLString]]; 

还有一种方法是将相应的字符串prefs:root=Photos 转换成成相应的ASCII进行组装

例如 

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"prefs:root=Photos"]];

转换

NSData *data_encrypted = [NSData dataWithBytes:(unsignedchar[]){0x70,0x72,0x65,0x66,0x73,0x3a,0x72,0x6f ,0x6f,0x74,0x3d,0x50,0x68,0x6f,0x74,0x6f,0x73} length:17]; 

NSString *method = [[NSString alloc] initWithData:data_encrypted encoding:NSASCIIStringEncoding];

[[UIApplication sharedApplication] openURL:[NSURL URLWithString:method]];

ASCII在线转换器

你可能感兴趣的:(iOS12发布之后审核被拒Guideline 2.5.1)