diff --git a/bot.go b/bot.go index 4be0e4d..bc4c948 100644 --- a/bot.go +++ b/bot.go @@ -3,6 +3,7 @@ package main import ( "fmt" tb "gopkg.in/tucnak/telebot.v2" + "regexp" "time" ) @@ -88,7 +89,7 @@ func botMsgRescan(m *tb.Message) (string, error) { if r.MatchString(m.Payload) { return "Rescaning msg #" + m.Payload, nil } - r := regexp.MustCompile("^all$") + r = regexp.MustCompile("^all$") if r.MatchString(m.Payload) { return "Rescaning all msg", nil }