From 65936f3a1b673f0520c6947cf43820a3f1278e99 Mon Sep 17 00:00:00 2001 From: Maurice Parker Date: Sun, 6 Nov 2022 13:32:20 -0600 Subject: [PATCH] Clear the Timeline when selecting a different Feed in the sidebar before loading it again. Fixes #3735. --- iOS/SceneCoordinator.swift | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/iOS/SceneCoordinator.swift b/iOS/SceneCoordinator.swift index bd6b25320..d6a970ff9 100644 --- a/iOS/SceneCoordinator.swift +++ b/iOS/SceneCoordinator.swift @@ -1963,8 +1963,10 @@ private extension SceneCoordinator { // To be called when we need to do an entire fetch, but an async delay is okay. // Example: we have the Today feed selected, and the calendar day just changed. cancelPendingAsyncFetches() + + emptyTheTimeline() + guard let timelineFeed = timelineFeed else { - emptyTheTimeline() completion() return } @@ -1980,7 +1982,6 @@ private extension SceneCoordinator { self?.replaceArticles(with: articles, animated: animated) completion() } - } func fetchUnsortedArticlesAsync(for representedObjects: [Any], completion: @escaping ArticleSetBlock) {