tabs/privatetab: Fixes #3491: Add MUC <x/> marker in MUC-PMs. Thanks Ge0rG.
From [XEP-0045 §7.5](https://xmpp.org/extensions/xep-0045.html#privatemessage): > To allow for proper synchronization of these messages to the user's > other clients by Message Carbons (XEP-0280) [19], the sending client > SHOULD add an element qualified by the > 'http://jabber.org/protocol/muc#user' namespace to the message. Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
2373015273
commit
0bf8727a92
1 changed files with 3 additions and 0 deletions
|
@ -13,6 +13,7 @@ the ConversationTab (such as tab-completion on nicks from the room).
|
|||
import curses
|
||||
import logging
|
||||
from typing import Dict, Callable
|
||||
from xml.etree import cElementTree as ET
|
||||
|
||||
from slixmpp import JID
|
||||
|
||||
|
@ -152,6 +153,8 @@ class PrivateTab(OneToOneTab):
|
|||
)
|
||||
msg['type'] = 'chat'
|
||||
msg['body'] = line
|
||||
x = ET.Element('{http://jabber.org/protocol/muc#user}x')
|
||||
msg.append(x)
|
||||
# trigger the event BEFORE looking for colors.
|
||||
# This lets a plugin insert \x19xxx} colors, that will
|
||||
# be converted in xhtml.
|
||||
|
|
Loading…
Reference in a new issue