Skip to content

Commit c5ab489

Browse files
committed
iOS: Ignore deprecation warning about using UNNotificationPresentationOptionAlert
- XCode could give a deprecation warning about using `UNNotificationPresentationOptionAlert` which is deprecated since iOS 14. The code is already written in such a way that it can only be used on iOS 13 and older versions. So ignore the deprecation warning.
1 parent 46560b0 commit c5ab489

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/ios/APPLocalNotification.m

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -494,7 +494,10 @@ - (void) userNotificationCenter:(UNUserNotificationCenter *)center
494494

495495
// iOS older then 14: Show notification as banner and in notification center
496496
} else {
497+
#pragma clang diagnostic push
498+
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
497499
presentationOptions |= UNNotificationPresentationOptionAlert;
500+
#pragma clang diagnostic pop
498501
}
499502
}
500503
}

0 commit comments

Comments
 (0)