[PATCH aerc] dirtree: fix dirlist-collapse=0 regression
Export this patch
Ensure not to collapse any folder when dirlist-collapse=0.
Fixes: 73dc39c6ee08 ("treewide: replace uint32 uids with opaque strings")
Reported-by: Tim Culverhouse <tim@timculverhouse.com>
Signed-off-by: Robin Jarry <robin@jarry.cc>
---
Thanks, Robin!
Tested-by: Tim Culverhouse <tim@timculverhouse.com>
Applied, thanks.
To git@git.sr.ht:~rjarry/aerc
49afb059bc98..7f69618ac1fd master -> master
app/dirtree.go | 3 ++ -
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/app/dirtree.go b/app/dirtree.go
index dc80fa7f7eb3..930f5f8e7f59 100644
--- a/app/dirtree.go
+++ b/app/dirtree.go
@@ -477,7 +477,8 @@ func (dt *DirectoryTree) buildTreeNode(node *types.Thread, dirs []string, depth
sort.Strings(bases)
basePath := dt.getDirectory(node)
- if depth > dt.UiConfig(basePath).DirListCollapse {
+ collapse := dt.UiConfig(basePath).DirListCollapse
+ if collapse != 0 && depth > collapse {
node.Hidden = 1
} else {
node.Hidden = 0
--
2.46.0
aerc/patches: SUCCESS in 1m54s
[dirtree: fix dirlist-collapse=0 regression][0] from [Robin Jarry][1]
[0]: https://lists.sr.ht/~rjarry/aerc-devel/patches/54865
[1]: mailto:robin@jarry.cc
✓ #1319093 SUCCESS aerc/patches/openbsd.yml https://builds.sr.ht/~rjarry/job/1319093
✓ #1319092 SUCCESS aerc/patches/alpine-edge.yml https://builds.sr.ht/~rjarry/job/1319092
Robin Jarry <robin@jarry.cc> wrote: