Browse Source

Stupid bug fix

drymer 3 years ago
parent
commit
9f718fc9bf
1 changed files with 1 additions and 2 deletions
  1. 1
    2
      jabbergram.py

+ 1
- 2
jabbergram.py View File

@@ -60,7 +60,7 @@ class EchoBot(sleekxmpp.ClientXMPP):
60 60
                     msg = user + ": " + message
61 61
                     chat_id = update.message.chat_id
62 62
 
63
-                    if message:
63
+                    if message and str(chat_id) in self.groups:
64 64
                         index = self.groups.index(str(chat_id))
65 65
                         receiver = self.muc_rooms[index]
66 66
 
@@ -77,7 +77,6 @@ class EchoBot(sleekxmpp.ClientXMPP):
77 77
                         else:
78 78
                             self.send_message(mto=receiver, mbody=msg,
79 79
                                                 mtype='groupchat')
80
-
81 80
                     update_id = update.update_id + 1
82 81
 
83 82
             except NetworkError as e:

Loading…
Cancel
Save