How to return back to previous view controller programmatically? I found this answer, but there is an example that demonstrate how to go back if we have navigation stack:
navigationController?.popViewControllerAnimated(true)
It's ok in case my queue of controllers based on navigation controller. But usually we use storyboard where we specify segue that marked with keyword Show that means we don't care about navigation push or present new view controllers. So in this case I presume there is only option with unwind view controller via segue, but maybe there is some simple call that I can do programmatically to go back to my previous view controller without checking if my stack of view controllers contain UINavigationController
or not.
I am looking for something simple like self.performSegueToReturnBack
.