summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2010-07-08 20:05:06 +0000
committerlouiz@4325f9fc-e183-4c21-96ce-0ab188b42d13 <louiz@4325f9fc-e183-4c21-96ce-0ab188b42d13>2010-07-08 20:05:06 +0000
commit3ae39c8027cdfe8bead53485a56f1c9b457d82eb (patch)
tree142f8ff36a1bddde8194175bfbafea36d7493850
parentf30040a88c771f39a6cb2cf2cdbf0a9ca93e0eb6 (diff)
downloadpoezio-3ae39c8027cdfe8bead53485a56f1c9b457d82eb.tar.gz
poezio-3ae39c8027cdfe8bead53485a56f1c9b457d82eb.tar.bz2
poezio-3ae39c8027cdfe8bead53485a56f1c9b457d82eb.tar.xz
poezio-3ae39c8027cdfe8bead53485a56f1c9b457d82eb.zip
fixed #1499 Also fix the '/join /sdf' bug that didn't update the new own_nick of the room
-rw-r--r--src/gui.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui.py b/src/gui.py
index abbe1329..6c698df3 100644
--- a/src/gui.py
+++ b/src/gui.py
@@ -434,11 +434,11 @@ class Gui(object):
elif kick:
room.users.remove(user)
try:
- reason = stanza.getReason().encode('utf-8')
+ reason = stanza.getReason()
except:
reason = ''
try:
- by = stanza.getActor().encode('utf-8')
+ by = stanza.getActor()
except:
by = None
if from_nick == room.own_nick: # we are kicked
@@ -446,7 +446,7 @@ class Gui(object):
if by:
self.add_message_to_room(room, _("You have been kicked by %(by)s. Reason: %(reason)s") % {'by':by, 'reason':reason})
else:
- self.add_message_to_room(room, _("You have been kicked. Reason: %s") % (reason.encode('utf-8')))
+ self.add_message_to_room(room, _("You have been kicked. Reason: %s") % (reason))
else:
if by:
self.add_message_to_room(room, _("%(nick)s has been kicked by %(by)s. Reason: %(reason)s") % {'nick':from_nick, 'by':by, 'reason':reason})
@@ -640,6 +640,7 @@ class Gui(object):
if not r: # if the room window exists, we don't recreate it.
self.join_room(room, nick)
else:
+ r.own_nick = nick
# r.own_nick = nick
r.users = []