comparison bridge.py @ 60:d8941159fd44

Fixed a little bug in bridge.py Signed-off-by: Charly COSTE <changaco@changaco.net>
author Charly COSTE <changaco@changaco.net>
date Fri, 28 Aug 2009 20:42:28 +0200
parents b048c4c03b00
children 61491895c607
comparison
equal deleted inserted replaced
59:0c00cf22492d 60:d8941159fd44
99 self.say('[Notice] bridge "'+str(self)+'" is running in '+self.mode+' mode', on_irc=False) 99 self.say('[Notice] bridge "'+str(self)+'" is running in '+self.mode+' mode', on_irc=False)
100 for error in errors: 100 for error in errors:
101 try: 101 try:
102 raise error 102 raise error
103 except xmpp.muc.NicknameConflict: 103 except xmpp.muc.NicknameConflict:
104 self.bot.error('[Error] "'+self.nickname+'" is already used in the XMPP MUC or reserved on the XMPP server of bridge "'+str(self)+'"') 104 self.bot.error('[Error] "'+self.bot.nickname+'" is already used in the XMPP MUC or reserved on the XMPP server of bridge "'+str(self)+'"')
105 raise Exception('[Error] "'+self.nickname+'" is already used in the XMPP MUC or reserved on the XMPP server of bridge "'+str(self)+'"') 105 raise Exception('[Error] "'+self.bot.nickname+'" is already used in the XMPP MUC or reserved on the XMPP server of bridge "'+str(self)+'"')
106 106
107 107
108 def addParticipant(self, protocol, nickname): 108 def addParticipant(self, protocol, nickname):
109 """Add a participant to the bridge.""" 109 """Add a participant to the bridge."""
110 if (protocol == 'irc' and nickname == self.irc_connection.get_nickname()) or (protocol == 'xmpp' and nickname == self.xmpp_room.nickname): 110 if (protocol == 'irc' and nickname == self.irc_connection.get_nickname()) or (protocol == 'xmpp' and nickname == self.xmpp_room.nickname):