Firebase Root View Controller Not Found Warning

故事扮演 提交于 2019-11-29 14:56:45

问题


I got a strange warning from Firebase Analytics today. It is:

<Warning> [Firebase/Analytics][I-ACS031011] Root view controller not found

The methods I am using is basically deleting a post and then displaying a status bar notification to the user that the post is deleted. This is the method that is called when we want to delete a post.

HomeViewNetwork.deletePost(postBlock: self.postDataBlock, handler: {
   AlertManager.showStatusRed(title: "Post deleted!")
})

And my displaying status function is:

class func showStatusRed(title: String) {
    let statusMessage = MessageView.viewFromNib(layout: .StatusLine)
    var config = SwiftMessages.defaultConfig
    config.presentationContext = .window(windowLevel: UIWindowLevelStatusBar)
    statusMessage.configureContent(body: title)
    statusMessage.backgroundView.backgroundColor = UIColor(red:0.98, green:0.11, blue:0.35, alpha:1.00)
    setUpStatusView(messageView: statusMessage)
    statusSwiftMessages.show(config: config, view: statusMessage)
}

The warning goes away if I comment the AlertManager.showStatusRed method. Also I am using SwiftMessages as my library for displaying the status bar notification.

I am not sure why Firebase is giving me this warning when Xcode is not giving any issues about root view controller. Any help is appreciated.

Related question for objective-C only project complied with Xcode 9 GM using FirebaseCore 4.0.4 (podfile.lock): Xcode 9 <Warning> [Firebase/Analytics][I-ACS031011] Root view controller not found


回答1:


Updating the firebase and other related dependencies to latest version fixed the issue on my project.

 - Firebase/Core (4.2.0):
 - FirebaseAnalytics (= 4.0.3)
 - FirebaseCore (= 4.0.7)

Answer on other thread: https://stackoverflow.com/a/46333312/342794



来源:https://stackoverflow.com/questions/45356479/firebase-root-view-controller-not-found-warning

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!