From 0d0fefb60caded8f5b3394665b875253be85980e Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Wed, 25 Nov 2026 14:43:46 -0800 Subject: [PATCH] Add restored Miniflux folder to tree before restoring its feeds, so the feeds end up in the folder. --- .../Account/Miniflux/MinifluxAccountDelegate.swift | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Modules/Account/Sources/Account/Miniflux/MinifluxAccountDelegate.swift b/Modules/Account/Sources/Account/Miniflux/MinifluxAccountDelegate.swift index 645a95c2e..e5ff50a59 100644 --- a/Modules/Account/Sources/Account/Miniflux/MinifluxAccountDelegate.swift +++ b/Modules/Account/Sources/Account/Miniflux/MinifluxAccountDelegate.swift @@ -521,9 +521,12 @@ import Secrets throw error } - for feed in folder.topLevelFeeds { - folder.topLevelFeeds.remove(feed) + // The folder goes in the tree first, so each restored feed finds it by externalID. + let feeds = folder.topLevelFeeds + folder.topLevelFeeds.removeAll() + account.addFolderToTree(folder) + for feed in feeds { do { try await restoreFeed(feed: feed, container: folder) } catch { @@ -531,8 +534,6 @@ import Secrets account.postSyncError(error, operation: "Restoring feed") } } - - account.addFolderToTree(folder) } }