mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2025-08-12 06:26:36 +00:00
Fix bug where clean up shortcut wouldn't clear articles if wrong setting was off.
This commit is contained in:
@@ -135,7 +135,7 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD
|
||||
|
||||
func manualRefresh(errorHandler: @escaping (Error) -> ()) {
|
||||
UIApplication.shared.connectedScenes.compactMap( { $0.delegate as? SceneDelegate } ).forEach {
|
||||
$0.cleanUp()
|
||||
$0.cleanUp(conditional: true)
|
||||
}
|
||||
AccountManager.shared.refreshAll(errorHandler: errorHandler)
|
||||
}
|
||||
|
||||
@@ -91,7 +91,7 @@ class RootSplitViewController: UISplitViewController {
|
||||
}
|
||||
|
||||
@objc func cleanUp(_ sender: Any?) {
|
||||
coordinator.cleanUp()
|
||||
coordinator.cleanUp(conditional: false)
|
||||
}
|
||||
|
||||
@objc func toggleReadFeedsFilter(_ sender: Any?) {
|
||||
|
||||
@@ -572,11 +572,11 @@ class SceneCoordinator: NSObject, UndoableCommandRunner, UnreadCountProvider {
|
||||
fetchRequestQueue.cancelAllRequests()
|
||||
}
|
||||
|
||||
func cleanUp() {
|
||||
func cleanUp(conditional: Bool) {
|
||||
if isReadFeedsFiltered {
|
||||
rebuildBackingStores()
|
||||
}
|
||||
if isReadArticlesFiltered && AppDefaults.refreshClearsReadArticles {
|
||||
if isReadArticlesFiltered && (AppDefaults.refreshClearsReadArticles || !conditional) {
|
||||
refreshTimeline(resetScroll: false)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -84,8 +84,8 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
|
||||
coordinator.suspend()
|
||||
}
|
||||
|
||||
func cleanUp() {
|
||||
coordinator.cleanUp()
|
||||
func cleanUp(conditional: Bool) {
|
||||
coordinator.cleanUp(conditional: conditional)
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user