Software /
code /
prosody
Changeset
9841:a44f562e01a5 0.11
mod_muc_mam: Strip the stanza 'to' attribute (fixes #1259)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 04 Mar 2019 12:56:31 +0100 |
parents | 9840:ec353524b739 |
children | 9842:6f39be2e0be5 |
files | plugins/mod_muc_mam.lua |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_muc_mam.lua Sun Mar 03 19:31:56 2019 +0100 +++ b/plugins/mod_muc_mam.lua Mon Mar 04 12:56:31 2019 +0100 @@ -208,6 +208,7 @@ if not is_stanza(item) then item = st.deserialize(item); end + item.attr.to = nil; item.attr.xmlns = "jabber:client"; fwd_st:add_child(item); @@ -329,6 +330,7 @@ if stanza.name == "message" and self:get_whois() == "anyone" then stored_stanza = st.clone(stanza); + stored_stanza.attr.to = nil; local actor = jid_bare(self._occupants[stanza.attr.from].jid); local affiliation = self:get_affiliation(actor) or "none"; local role = self:get_role(actor) or self:get_default_role(affiliation);