From 0013b1fe2b10818b3441e0ddc96cd9d8d8b11bbc Mon Sep 17 00:00:00 2001 From: = Date: Wed, 24 Nov 2021 10:05:28 -0500 Subject: [PATCH] Add debugging --- discordMessage.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/discordMessage.go b/discordMessage.go index 6407538..570495f 100644 --- a/discordMessage.go +++ b/discordMessage.go @@ -12,6 +12,7 @@ import ( func messageCreate(s *discordgo.Session, m *discordgo.MessageCreate) { defer log.PanicSafe() if m.Author.ID == "302050872383242240" && strings.Contains(m.Content, "minutes until the server can be bumped") { + log.LogDebug("Failed bump detected") re := regexp.MustCompile("Please wait another (.*) minutes until the server can be bumped") match := re.FindStringSubmatch(m.Content) m.Content = fmt.Sprintf("@Thanos bs %+v", match[1]) @@ -21,6 +22,9 @@ func messageCreate(s *discordgo.Session, m *discordgo.MessageCreate) { Session: s, Parts: strings.Split(m.Content, " ")[2:], }) + } else { + log.LogDebug("Not a failed bump.") + log.LogDebug(fmt.Sprintf("%+v: %+v", m.Author.ID, m.Content)) } if m.Author.ID == s.State.User.ID || m.Author.Bot { return