问题:
Terminating app due to uncaught exception ‘NSInvalidArgumentException‘, reason: ‘Application tried to present modally an active controller <TabbarViewController: 0x1765dbe0>.‘
解决方法:
判断controller是不是有presentedViewController,没有的话才可以present
if ([UIApplication sharedApplication].delegate.window.rootViewController.presentedViewController == nil) { [[UIApplication sharedApplication].delegate.window.rootViewController presentViewController:self.gesturePasswordController animated:YES completion:^{ }]; }
时间: 2024-10-08 07:07:26