I am getting this error when I call my method dismissView. Here is the method stub:
-(IBAction)dismissView { RootViewController *rootController = [[RootViewC
In my case the problem was that I was in the root ViewController and this works only for VCs that are stacked over it. To pop to the RootViewController use
navigationController?.popToRootViewController(animated: true)