Mercurial > xib
comparison bot.py @ 27:9b7a628ca612
Fixed XMPP message handling, again.
Signed-off-by: Charly COSTE <changaco@changaco.net>
author | Charly COSTE <changaco@changaco.net> |
---|---|
date | Fri, 21 Aug 2009 00:46:09 +0200 |
parents | a9066c416533 |
children | a694ffe6a973 |
comparison
equal
deleted
inserted
replaced
26:1691ab4d131f | 27:9b7a628ca612 |
---|---|
171 if from_bare_jid == bridge.xmpp_room.room_jid: | 171 if from_bare_jid == bridge.xmpp_room.room_jid: |
172 # message comes from a room participant | 172 # message comes from a room participant |
173 | 173 |
174 try: | 174 try: |
175 from_ = bridge.getParticipant(message.getFrom().getResource()) | 175 from_ = bridge.getParticipant(message.getFrom().getResource()) |
176 to_ = bridge.getParticipant(message.getTo().getResource()) | 176 to_ = bridge.getParticipant(xmpp_c.nickname) |
177 | 177 |
178 if from_.protocol == 'xmpp': | 178 if from_.protocol == 'xmpp': |
179 from_.sayOnIRCTo(to_.nickname, message.getBody()) | 179 from_.sayOnIRCTo(to_.nickname, message.getBody()) |
180 else: | 180 else: |
181 self.error('=> Debug: received XMPP chat message from a non-XMPP participant, WTF ?', debug=True) | 181 self.error('=> Debug: received XMPP chat message from a non-XMPP participant, WTF ?', debug=True) |