From 78e16b0e29baccb458e9e498f08562b0ca4b3b38 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Fri, 1 May 2020 19:43:21 -0700 Subject: [PATCH] Fix crash on iOS 8 --- Limelight/AppDelegate.m | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Limelight/AppDelegate.m b/Limelight/AppDelegate.m index 5db73f57..c8668c3c 100644 --- a/Limelight/AppDelegate.m +++ b/Limelight/AppDelegate.m @@ -24,9 +24,11 @@ static NSString* DB_NAME = @"Limelight_iOS.sqlite"; - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { #if !TARGET_OS_TV - UIApplicationShortcutItem* shortcut = [launchOptions valueForKey:UIApplicationLaunchOptionsShortcutItemKey]; - if (shortcut != nil) { - _pcUuidToLoad = (NSString*)[shortcut.userInfo objectForKey:@"UUID"]; + if (@available(iOS 9.0, *)) { + UIApplicationShortcutItem* shortcut = [launchOptions valueForKey:UIApplicationLaunchOptionsShortcutItemKey]; + if (shortcut != nil) { + _pcUuidToLoad = (NSString*)[shortcut.userInfo objectForKey:@"UUID"]; + } } #endif return YES;