该应用程序引用非公开选择在有效载荷/ 的.app/:FailWithError:,topMostAlert

问题描述:

在苹果应用程序上传我得到这个错误:该应用程序引用非公开选择在有效载荷/ <Appname>的.app/<App name>:FailWithError:,topMostAlert

The app references non-public selectors in Payload/<Appname>.app/<App name>: FailWithError: , topMostAlert

我搜索了我的代码FailWithError:topMostAlert。 我没有找到这些在我的代码,除了用于关闭UIAlertView

Class UIAlertManager = NSClassFromString(@"_UIAlertManager"); 
UIAlertView *alertView = [UIAlertManager performSelector:@selector(topMostAlert)]; 
[alertView dismissWithClickedButtonIndex:0 animated:NO]; 

我知道这个错误是因为在自己的代码或第三方代码,具有相同的名称为一些选择是使用选择的topMostAlert标记为非公开(Apple提供的API)。

我添加了我的代码中使用的框架截图。

enter image description here

,因为你使用的是私有类UIAlertManager(通过_UIAlertManager)你被拒绝。更改您的代码,以便仅使用公开的APIs,它将通过审查过程。

+0

我想出了同样的感谢。在显示新的之前,我实际上想要解除先前的UIAlertView。所以以前不在那里。在ios7中,我们可以通过UIAlertManager来完成。 – Xeieshan

+0

topMostAlert问题是走了,但苹果仍然显示警告 '该应用程序引用非公开选择在有效载荷/ 的.app/:FailWithError:' 的警告了。 – Xeieshan

+0

只要忽略警告即可。没什么。这只意味着你的一个方法与Apple的命名方式相同。 – RaffAl