Change to no longer filter currently selected Feed. Issue #1728

This commit is contained in:
Maurice Parker 2020-01-28 16:51:50 -07:00
parent b53cbfcf2c
commit 76aa603874
1 changed files with 21 additions and 1 deletions

View File

@ -1251,11 +1251,31 @@ private extension SceneCoordinator {
func rebuildBackingStores(initialLoad: Bool = false, updateExpandedNodes: (() -> Void)? = nil) {
if !animatingChanges && !BatchUpdate.shared.isPerforming {
addCurrentFeedToFilterExeptionsIfNecessary()
treeController.rebuild()
treeControllerDelegate.resetFilterExceptions()
updateExpandedNodes?()
rebuildShadowTable()
masterFeedViewController.reloadFeeds(initialLoad: initialLoad)
clearTimelineIfNoLongerAvailable()
}
}
func addCurrentFeedToFilterExeptionsIfNecessary() {
if isReadFeedsFiltered, let feedID = timelineFeed?.feedID {
if timelineFeed is SmartFeed {
treeControllerDelegate.addFilterException(feedID)
} else if let folderFeed = timelineFeed as? Folder {
if folderFeed.account?.existingFolder(withID: folderFeed.folderID) != nil {
treeControllerDelegate.addFilterException(feedID)
}
} else if let webFeed = timelineFeed as? WebFeed {
if webFeed.account?.existingWebFeed(withWebFeedID: webFeed.webFeedID) != nil {
treeControllerDelegate.addFilterException(feedID)
}
}
}
}