In my app latest notification is replacing previous one, how to stop this behavior show that all notifications are shown in notification center until user clears.
if #available(iOS 10.0, *) {
let center = UNUserNotificationCenter.current()
//center.delegate = self
center.requestAuthorization(options: [.sound, .alert, .badge]) { (granted, error) in
if error == nil{
UIApplication.shared.registerForRemoteNotifications()
}
}
} else {
UIApplication.shared.registerUserNotificationSettings(UIUserNotificationSettings(types: [.sound, .alert, .badge], categories: nil))
UIApplication.shared.registerForRemoteNotifications()
}