From cc2c90c4e3d99471757be33ae22768186f7f94b4 Mon Sep 17 00:00:00 2001 From: Luther Wen Xu Date: Sat, 12 Oct 2019 20:34:37 +0800 Subject: [PATCH] go: Fix compare command names after forcing lowercase --- GoBot/discord/listener.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GoBot/discord/listener.go b/GoBot/discord/listener.go index 2fc868f..ab0f995 100644 --- a/GoBot/discord/listener.go +++ b/GoBot/discord/listener.go @@ -16,7 +16,7 @@ func ProcessCommand(s *discordgo.Session, m *discordgo.MessageCreate) { command := strings.Split(m.Content, " ") for _, v := range modules.Commands { - if v.Name == strings.toLower(command[0]) { + if v.Name == strings.ToLower(command[0]) { v.Handler(s, m, command) return }