mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-12-03 18:56:14 +00:00
Remove duplicate remote notification registration.
This commit is contained in:
1 parent
850577d6bc
commit
b7472fcdaa
1 file changed
+2
-8
@@ -231,13 +231,8 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
|
||||
refreshTimer = AccountRefreshTimer()
|
||||
syncTimer = ArticleStatusSyncTimer()
|
||||
|
||||
UNUserNotificationCenter.current().requestAuthorization(options:[.badge, .sound, .alert]) { (granted, error) in
|
||||
if granted {
|
||||
DispatchQueue.main.async {
|
||||
NSApplication.shared.registerForRemoteNotifications()
|
||||
}
|
||||
}
|
||||
}
|
||||
UNUserNotificationCenter.current().requestAuthorization(options:[.badge, .sound, .alert]) { (granted, error) in }
|
||||
NSApplication.shared.registerForRemoteNotifications()
|
||||
|
||||
UNUserNotificationCenter.current().delegate = self
|
||||
userNotificationManager = UserNotificationManager()
|
||||
@@ -268,7 +263,6 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSUserInterfaceValidations,
|
||||
}
|
||||
#endif
|
||||
|
||||
NSApplication.shared.registerForRemoteNotifications()
|
||||
}
|
||||
|
||||
func application(_ application: NSApplication, continue userActivity: NSUserActivity, restorationHandler: @escaping ([NSUserActivityRestoring]) -> Void) -> Bool {
|
||||
|
||||
Reference in new issue
Block a user