From ce0c95d0972476f1e5a0064edbceb33d3ceed6ba Mon Sep 17 00:00:00 2001 From: lulz <92385434+lulzshadowwalker@users.noreply.github.com> Date: Tue, 20 Feb 2024 05:56:49 +0300 Subject: [PATCH] [fix] /bye and /exit are now treated as prefixes (#2381) * [fix] /bye and /exit are now treated as prefixes instead of being treated as entire lines which doesn't align with the way the rest of the commands are treated * Update cmd/interactive.go Fixing whitespace --------- Co-authored-by: Jeffrey Morgan --- cmd/interactive.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/interactive.go b/cmd/interactive.go index a421a513..82e3642a 100644 --- a/cmd/interactive.go +++ b/cmd/interactive.go @@ -470,7 +470,7 @@ func generateInteractive(cmd *cobra.Command, opts runOptions) error { } else { usage() } - case line == "/exit", line == "/bye": + case strings.HasPrefix(line, "/exit"), strings.HasPrefix(line, "/bye"): return nil case strings.HasPrefix(line, "/"): args := strings.Fields(line)