From 51a2c85954e77068c6afbb4ca54159086220aefd Mon Sep 17 00:00:00 2001 From: Michael Muré Date: Sat, 17 Apr 2021 17:40:11 +0200 Subject: make sure every text input is safe and validated fix #630 --- commands/label_rm.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'commands/label_rm.go') diff --git a/commands/label_rm.go b/commands/label_rm.go index f59ec02d..9fb3e096 100644 --- a/commands/label_rm.go +++ b/commands/label_rm.go @@ -4,6 +4,7 @@ import ( "github.com/spf13/cobra" _select "github.com/MichaelMure/git-bug/commands/select" + "github.com/MichaelMure/git-bug/util/text" ) func newLabelRmCommand() *cobra.Command { @@ -30,7 +31,7 @@ func runLabelRm(env *Env, args []string) error { removed := args - changes, _, err := b.ChangeLabels(nil, removed) + changes, _, err := b.ChangeLabels(nil, text.CleanupOneLineArray(removed)) for _, change := range changes { env.out.Println(change) -- cgit