dismissViewController doesn't call it's completing handler all the time. I am presenting first view, when I dismiss it, it calls completion handler, where I am presenting 2 view. While dismissing 2nd view, completion handler is not being called. Here is my code:
if self.presentedViewController != nil {
// Checking it to make sure that I have presentedViewController and it is not dismissed already.
self.dismissViewControllerAnimated(false, completion: {
//Present 2nd controller.
})
}