From 1e25ba1710d4ff11c2c5de2603a2903074a8bcd8 Mon Sep 17 00:00:00 2001 From: Nicolas MASSE Date: Mon, 23 Dec 2019 18:31:35 +0100 Subject: [PATCH] handle errors --- main.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main.go b/main.go index edd6f5e..60b0bdc 100644 --- a/main.go +++ b/main.go @@ -213,6 +213,10 @@ func main() { } dispatchMessage(bot, update.Message) replyWithMessage(bot, update.Message, viper.GetString("MsgThankYouMedia")) + } else { + log.Printf("[%s] cannot handle this type of message", username) + replyToCommandWithMessage(bot, update.Message, viper.GetString("MsgDoNotUnderstand")) + continue } } }