get real jid of contact we want to ban from a room. Fixes #2521
This commit is contained in:
parent
0a572cf822
commit
b821d23f70
1 changed files with 4 additions and 5 deletions
|
@ -1116,11 +1116,10 @@ class GroupchatControl(ChatControlBase):
|
||||||
self.room_jid)
|
self.room_jid)
|
||||||
reason = ' '.join(message_array)
|
reason = ' '.join(message_array)
|
||||||
if nick in room_nicks:
|
if nick in room_nicks:
|
||||||
ban_jid = gajim.construct_fjid(self.room_jid, nick)
|
gc_contact = gajim.contacts.get_gc_contact(self.account,
|
||||||
gajim.connections[self.account].gc_set_affiliation(self.room_jid,
|
self.room_jid, nick)
|
||||||
ban_jid, 'outcast', reason)
|
nick = gc_contact.jid
|
||||||
self.clear(self.msg_textview)
|
if nick.find('@') >= 0:
|
||||||
elif nick.find('@') >= 0:
|
|
||||||
gajim.connections[self.account].gc_set_affiliation(self.room_jid,
|
gajim.connections[self.account].gc_set_affiliation(self.room_jid,
|
||||||
nick, 'outcast', reason)
|
nick, 'outcast', reason)
|
||||||
self.clear(self.msg_textview)
|
self.clear(self.msg_textview)
|
||||||
|
|
Loading…
Add table
Reference in a new issue