From 6094b074cc887155df7c29d871490a49f864ec90 Mon Sep 17 00:00:00 2001 From: Alexei Sorokin Date: Wed, 22 Feb 2017 01:16:14 +0300 Subject: [PATCH] Before handling a message, check the sender if the bot --- hptoad.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hptoad.py b/hptoad.py index 1c8b337..83be20f 100755 --- a/hptoad.py +++ b/hptoad.py @@ -215,7 +215,8 @@ class Hptoad: if event["type"] == "groupchat": nick = event["mucnick"] - self.handle_muc_message(body, nick, from_id) + if nick != self.bot_nick: + self.handle_muc_message(body, nick, from_id) elif event["from"].bare == self.jid: # Use resource as a nickname with self messages.