Software /
code /
prosody
Diff
plugins/mod_pubsub/mod_pubsub.lua @ 9187:bd452e4f5a13
mod_pubsub: Only attach publisher on normal "item" broadcasts
The 'publisher' is only on <item> in the schema.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Thu, 16 Aug 2018 15:18:29 +0200 |
parent | 9181:79cf1f74738f |
child | 9188:ef2616ade453 |
line wrap: on
line diff
--- a/plugins/mod_pubsub/mod_pubsub.lua Thu Aug 16 15:07:28 2018 +0200 +++ b/plugins/mod_pubsub/mod_pubsub.lua Thu Aug 16 15:18:29 2018 +0200 @@ -59,8 +59,10 @@ if item then item = st.clone(item); item.attr.xmlns = nil; -- Clear the pubsub namespace - if expose_publisher and actor then - item.attr.publisher = actor + if kind == "items" then + if expose_publisher and actor then + item.attr.publisher = actor + end end end