plugin XEP-0313: fix value used in msg_from when from is not explicitely specified.

This commit is contained in:
Goffi 2024-03-05 17:31:56 +01:00
commit bb57b12329

View file

@ -268,7 +268,7 @@ class XEP_0313(object):
xml=mess_elt.toXml()))
raise exceptions.DataError("Invalid element")
service_jid = client.jid.userhostJID() if service is None else service
mess_from = mess_elt.getAttribute("from") or client.jid.userhostJID()
mess_from = mess_elt.getAttribute("from") or client.jid.userhost()
# we check that the message has been sent by the right service
# if service is None (i.e. message expected from our own server)
# from can be server jid or user's bare jid