mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2025-01-20 13:38:24 +01:00
Only dispatch UI code for async execution
This commit is contained in:
parent
193aab2cef
commit
88ac27ef50
@ -173,9 +173,9 @@ private extension WebFeedInspectorViewController {
|
|||||||
|
|
||||||
func updateNotificationSettings() {
|
func updateNotificationSettings() {
|
||||||
UNUserNotificationCenter.current().getNotificationSettings { (settings) in
|
UNUserNotificationCenter.current().getNotificationSettings { (settings) in
|
||||||
DispatchQueue.main.async {
|
self.userNotificationSettings = settings
|
||||||
self.userNotificationSettings = settings
|
if settings.authorizationStatus == .authorized {
|
||||||
if settings.authorizationStatus == .authorized {
|
DispatchQueue.main.async {
|
||||||
NSApplication.shared.registerForRemoteNotifications()
|
NSApplication.shared.registerForRemoteNotifications()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user