Question: I have encountered this warning:

> 
> pushViewController:animated: called on while an existing transition or presentation is
>  occurring; the navigation stack will not be updated.
> 
> 
> 

While trying to call `navigationController?.popViewControllerAnimated(false)` from `UIAlertController` completion block.

Answer: 
i am using **dispatch\_async** and **its working**. i tried to navigate back but didn't worked **because navigation stack will not be updated.**

```
let destVC = self.storyboard?.instantiateViewControllerWithIdentifier("HomeViewController") as! HomeViewController
    self.presentViewController(destVC, animated: true, completion: {() -> Void in
        dispatch_async(dispatch_get_main_queue(), {() -> Void in
            self.navigationController?.popViewControllerAnimated(true)!
        })
    })

```
My Solution would be to call dismissViewControllerAnimated: first and then pop the viewcontroller from navigation stack this works for me :-

```
[self dismissViewControllerAnimated:false completion:nil];
[myNavigationControllerInstance popToRootViewControllerAnimated:true]; // myNavigationControllerInstance = Your Navigation Controller Instance

```