mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-11-28 08:17:16 +00:00
Fix concurrency crash by running code on MainActor that’s supposed to be on MainActor. Fix #4934.
This commit is contained in:
1 parent
98046b3e62
commit
b2c9cb6fd8
2 files changed
+12
-9
No files matched your search
@@ -65,16 +65,17 @@ extension AppDelegate: AppDelegateAppleEvents {
|
||||
return
|
||||
}
|
||||
|
||||
do {
|
||||
try ArticleThemeDownloader.shared.handleFile(at: location)
|
||||
} catch {
|
||||
NotificationCenter.default.post(name: .didFailToImportThemeWithError, object: nil, userInfo: ["error": error])
|
||||
Task { @MainActor in
|
||||
do {
|
||||
try ArticleThemeDownloader.shared.handleFile(at: location)
|
||||
} catch {
|
||||
NotificationCenter.default.post(name: .didFailToImportThemeWithError, object: nil, userInfo: ["error": error])
|
||||
}
|
||||
}
|
||||
}
|
||||
task.resume()
|
||||
}
|
||||
return
|
||||
|
||||
}
|
||||
|
||||
// Special case URL with specific scheme handler x-netnewswire-feed: intended to ensure we open
|
||||
|
||||
Reference in new issue
Block a user