mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2025-01-31 19:24:55 +01:00
Reuse account nodes, which should fix at least one cause of the bug where sometimes the On My Mac group item collapses when it shouldn’t.
This commit is contained in:
parent
c65757bab3
commit
7d68e3322c
@ -107,7 +107,12 @@ private extension SidebarTreeControllerDelegate {
|
||||
|
||||
func sortedAccountNodes(_ parent: Node) -> [Node] {
|
||||
|
||||
let nodes = AccountManager.shared.accounts.map { createNode(account: $0, parent: parent) }
|
||||
let nodes = AccountManager.shared.accounts.map { (account) -> Node in
|
||||
let accountNode = parent.existingOrNewChildNode(with: account)
|
||||
accountNode.canHaveChildNodes = true
|
||||
accountNode.isGroupItem = true
|
||||
return accountNode
|
||||
}
|
||||
return nodes.sortedAlphabetically()
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user