prevent showing twice the same message in muc when we are twice in a room from 2 accounts.
This commit is contained in:
parent
2315d8a14a
commit
186b84c481
|
@ -1042,6 +1042,7 @@ class GcMessageReceivedEvent(nec.NetworkIncomingEvent):
|
|||
self.fjid = self.msg_obj.fjid
|
||||
self.msgtxt = self.msg_obj.msgtxt
|
||||
self.jid = self.msg_obj.jid
|
||||
self.room_jid = self.msg_obj.jid
|
||||
self.timestamp = self.msg_obj.timestamp
|
||||
self.xhtml_msgtxt = self.stanza.getXHTML()
|
||||
|
||||
|
|
|
@ -811,7 +811,7 @@ class GroupchatControl(ChatControlBase):
|
|||
menu.destroy()
|
||||
|
||||
def _nec_gc_message_received(self, obj):
|
||||
if obj.jid != self.room_jid:
|
||||
if obj.room_jid != self.room_jid or obj.conn.name != self.account:
|
||||
return
|
||||
if obj.captcha_form:
|
||||
if self.form_widget:
|
||||
|
@ -1270,7 +1270,7 @@ class GroupchatControl(ChatControlBase):
|
|||
self.draw_role(role)
|
||||
|
||||
def _nec_gc_presence_received(self, obj):
|
||||
if obj.room_jid != self.room_jid:
|
||||
if obj.room_jid != self.room_jid or obj.conn.name != self.account:
|
||||
return
|
||||
if obj.ptype == 'error':
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue