在UIAlertController彈窗后,使用popToViewController返回上級頁面,報錯
popToViewController:transition: called on <UINavigationController 0x7fc27b8ac000> while an existing transition or presentation is occurring; the navigation stack will not be updated.
原因是當UIAlertController在執(zhí)行的時候,不能進行堆棧的操作,navigation的堆棧更新不成功,所以頁面不能跳轉
解決辦法就是: 在block方法里面執(zhí)行方法,讓UIAlertController先完成操作如圖:
屏幕快照 2017-02-17 下午1.22.21.png