Convert markArticles to async await.

This commit is contained in:
Brent Simmons
2024-03-26 18:48:44 -07:00
parent bf58443fe1
commit 402ee970cc
11 changed files with 105 additions and 23 deletions

View File

@@ -449,11 +449,11 @@ private extension AppDelegate {
return
}
account.markArticles(articles, statusKey: .read, flag: true) { _ in }
try? await account.markArticles(articles, statusKey: .read, flag: true)
self.prepareAccountsForBackground()
try? await account.syncArticleStatus
try? await account.syncArticleStatus()
if !self.accountManager.isSuspended {
try? WidgetDataEncoder.shared.encodeWidgetData()
self.prepareAccountsForBackground()
@@ -486,7 +486,7 @@ private extension AppDelegate {
return
}
account.markArticles(articles, statusKey: .starred, flag: true) { _ in }
try? await account.markArticles(articles, statusKey: .starred, flag: true)
try? await account.syncArticleStatus()
if !self.accountManager.isSuspended {