Refresh smart feeds when articles refresh.
This commit is contained in:
parent
ed37282c79
commit
cda559728c
|
@ -419,7 +419,7 @@ class TimelineViewController: NSViewController, UndoableCommandRunner {
|
|||
return
|
||||
}
|
||||
|
||||
let shouldFetchAndMergeArticles = representedObjectsContainsAnyFeed(feeds)
|
||||
let shouldFetchAndMergeArticles = representedObjectsContainsAnyFeed(feeds) || representedObjectsContainsAnyPseudoFeed()
|
||||
if shouldFetchAndMergeArticles {
|
||||
queueFetchAndMergeArticles()
|
||||
}
|
||||
|
@ -850,6 +850,18 @@ private extension TimelineViewController {
|
|||
return true
|
||||
}
|
||||
|
||||
func representedObjectsContainsAnyPseudoFeed() -> Bool {
|
||||
guard let representedObjects = representedObjects else {
|
||||
return false
|
||||
}
|
||||
for representedObject in representedObjects {
|
||||
if representedObject is PseudoFeed {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func representedObjectsContainsAnyFeed(_ feeds: Set<Feed>) -> Bool {
|
||||
|
||||
// Return true if there’s a match or if a folder contains (recursively) one of feeds
|
||||
|
|
Loading…
Reference in New Issue