From 424b191ebc0e382a75901de7bf46799217ff51c4 Mon Sep 17 00:00:00 2001 From: Ryan Cavicchioni Date: Fri, 26 Aug 2022 17:55:51 -0500 Subject: [PATCH] Fix HasCommand() It was not working if the command had an argument --- lib/common.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/common.go b/lib/common.go index be22fcd..5ec3b95 100644 --- a/lib/common.go +++ b/lib/common.go @@ -59,7 +59,7 @@ func HasCommand(s, prefix, cmd string) bool { return false } - if s[1:] == cmd { + if strings.HasPrefix(s[1:], cmd) { return true }