@@ -384,7 +384,6 @@ - (void)handleIncomingLinkIfNeededFromMessage:(NSDictionary *)message {
384
384
id <UIApplicationDelegate> appDelegate = application.delegate ;
385
385
SEL continueUserActivitySelector =
386
386
@selector (application:continueUserActivity:restorationHandler: );
387
- SEL openURLWithOptionsSelector = @selector (application:openURL:options: );
388
387
SEL openURLWithSourceApplicationSelector =
389
388
@selector (application:openURL:sourceApplication:annotation: );
390
389
SEL handleOpenURLSelector = @selector (application:handleOpenURL: );
@@ -403,7 +402,7 @@ - (void)handleIncomingLinkIfNeededFromMessage:(NSDictionary *)message {
403
402
// Do nothing, as we don't support the app calling this block
404
403
}];
405
404
406
- } else if ([appDelegate respondsToSelector: openURLWithOptionsSelector] ) {
405
+ } else if (@ available (iOS 9.0 , *) ) {
407
406
[appDelegate application: application openURL: url options: @{}];
408
407
409
408
// Similarly, |application:openURL:sourceApplication:annotation:| will also always be called, due
@@ -727,7 +726,7 @@ - (void)setAPNSToken:(NSData *)apnsToken error:(NSError *)error {
727
726
728
727
- (void )receiver : (FIRMessagingReceiver *)receiver
729
728
receivedRemoteMessage : (FIRMessagingRemoteMessage *)remoteMessage {
730
- if ([ self .delegate respondsToSelector: @selector ( messaging:didReceiveMessage: )] ) {
729
+ if (@ available (iOS 10.0 , *) ) {
731
730
[self .delegate messaging: self didReceiveMessage: remoteMessage];
732
731
} else if ([self .delegate respondsToSelector: @selector (applicationReceivedRemoteMessage: )]) {
733
732
#pragma clang diagnostic push
0 commit comments