I am trying to use Firebase to handle push notifications. I have installed Firebase
pod (\'Firebase/Core\' and \'FirebaseMessaging\' pods).
And after I impo
UserNotifications.framework
is available from iOS 10 and you are working with Xcode 7.3 means with iOS 9 and lower, So there is no need for you to add that if #available(iOS 10.0, *) {
, write only else part directly and register remote notifications.
let settings: UIUserNotificationSettings = UIUserNotificationSettings(forTypes: [.Alert, .Badge, .Sound], categories: nil)
application.registerUserNotificationSettings(settings)
application.registerForRemoteNotifications()