Software /
code /
prosody
Diff
plugins/muc/muc.lib.lua @ 9194:11a0b32fef24
MUC: Direct PubSub queries to occupants to their real bare JID
This allows accessing PEP nodes of participants without knowing their
real JIDs.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 18 Aug 2018 14:06:23 +0200 |
parent | 9148:a474c94d0b0a |
child | 9237:b86c2e135797 |
line wrap: on
line diff
--- a/plugins/muc/muc.lib.lua Sat Aug 18 00:41:49 2018 +0200 +++ b/plugins/muc/muc.lib.lua Sat Aug 18 14:06:23 2018 +0200 @@ -727,7 +727,8 @@ end stanza.attr.from, stanza.attr.to = current_nick, occupant.jid; log("debug", "%s sent private iq stanza to %s (%s)", from, to, occupant.jid); - if stanza.tags[1].attr.xmlns == 'vcard-temp' then + local iq_ns = stanza.tags[1].attr.xmlns; + if iq_ns == 'vcard-temp' or iq_ns == "http://jabber.org/protocol/pubsub" then stanza.attr.to = jid_bare(stanza.attr.to); end self:route_stanza(stanza);