~rjarry/aerc-devel

aerc: commands: fix empty entries from completion funcs v1 APPLIED

Koni Marti: 1
 commands: fix empty entries from completion funcs

 2 files changed, 2 insertions(+), 2 deletions(-)
#1365552 alpine-edge.yml success
#1365553 openbsd.yml success
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~rjarry/aerc-devel/patches/55889/mbox | git am -3
Learn more about email & git

[PATCH aerc] commands: fix empty entries from completion funcs Export this patch

Fix the commands.GetTemplates() and types.StrategyStrs() completion
functions to avoid showing empty entries.

Reported-by: pam79
Reported-by: inwit <inwit@sindominio.net>
Signed-off-by: Koni Marti <koni.marti@gmail.com>
---
 commands/commands.go | 2 +-
 worker/types/mfs.go  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/commands/commands.go b/commands/commands.go
index a06e8ef9..19bb5d66 100644
--- a/commands/commands.go
+++ b/commands/commands.go
@@ -308,7 +308,7 @@ func GetTemplates(arg string) []string {
			}
		}
	}
	names := make([]string, len(templates))
	names := make([]string, 0, len(templates))
	for n := range templates {
		names = append(names, n)
	}
diff --git a/worker/types/mfs.go b/worker/types/mfs.go
index 071eda1d..a842082f 100644
--- a/worker/types/mfs.go
+++ b/worker/types/mfs.go
@@ -25,7 +25,7 @@ var StrToStrategy = map[string]MultiFileStrategy{
}

func StrategyStrs() []string {
	strs := make([]string, len(StrToStrategy))
	strs := make([]string, 0, len(StrToStrategy))
	for s := range StrToStrategy {
		strs = append(strs, s)
	}
-- 
2.47.0
aerc/patches: SUCCESS in 2m2s

[commands: fix empty entries from completion funcs][0] from [Koni Marti][1]

[0]: https://lists.sr.ht/~rjarry/aerc-devel/patches/55889
[1]: mailto:koni.marti@gmail.com

✓ #1365553 SUCCESS aerc/patches/openbsd.yml     https://builds.sr.ht/~rjarry/job/1365553
✓ #1365552 SUCCESS aerc/patches/alpine-edge.yml https://builds.sr.ht/~rjarry/job/1365552
Koni Marti <koni.marti@gmail.com> wrote: