Hi guys! I found an issue and actually is pretty easy to fix. I'm seeing that MFMailComposeViewControllerDelegate (in RNMail.m) is not dismissing the MFMailComposeViewController, instead of that look on the rootViewController this is causing that the MFMailComposeViewController remains on screen after tap cancel or send. I added the following line and it's working
[controller dismissViewControllerAnimated:YES completion:nil];
My question is why looking into rootViewController instead of just dismiss the controller?
UIViewController *ctrl = [[[[UIApplication sharedApplication] delegate] window] rootViewController];
while (ctrl.presentedViewController && ctrl != controller) {
ctrl = ctrl.presentedViewController;
}
[ctrl dismissViewControllerAnimated:YES completion:nil];
Hi guys! I found an issue and actually is pretty easy to fix. I'm seeing that
MFMailComposeViewControllerDelegate(inRNMail.m) is not dismissing theMFMailComposeViewController, instead of that look on therootViewControllerthis is causing that theMFMailComposeViewControllerremains on screen after tap cancel or send. I added the following line and it's working[controller dismissViewControllerAnimated:YES completion:nil];My question is why looking into rootViewController instead of just dismiss the controller?