From 5228ead9c916b40b1ebdb922696be7a088c414fc Mon Sep 17 00:00:00 2001 From: Jimmy Dee Date: Fri, 22 Dec 2017 08:55:36 -0800 Subject: [PATCH] Get rid of unnecessary version check for iOS 8 --- ios/RNBranch.m | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/ios/RNBranch.m b/ios/RNBranch.m index 12763a657..ee92e6ec5 100644 --- a/ios/RNBranch.m +++ b/ios/RNBranch.m @@ -219,13 +219,8 @@ - (void) dealloc { - (UIViewController *)currentViewController { UIViewController *current = [UIApplication sharedApplication].keyWindow.rootViewController; - if (@available(iOS 8.0, *)) { - while (current.presentedViewController && ![current.presentedViewController isKindOfClass:UIAlertController.class]) { - current = current.presentedViewController; - } - } else { - // RN Requires iOS 8. Nothing to do here. Still. - while (current.presentedViewController) current = current.presentedViewController; + while (current.presentedViewController && ![current.presentedViewController isKindOfClass:UIAlertController.class]) { + current = current.presentedViewController; } return current; }