diff options
author | Kim Alvefur <zash@zash.se> | 2018-06-26 19:36:23 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2018-06-26 19:36:23 +0200 |
commit | d17ebcbfe8e3f9b6b56ad897c630481ca4fab7a1 (patch) | |
tree | bbc97750f5ecd7b73a3d0952ccf9199adbad5a88 | |
parent | 359a86ca08233d3b445dc9a342b7377eaa5a697d (diff) | |
download | prosody-d17ebcbfe8e3f9b6b56ad897c630481ca4fab7a1.tar.gz prosody-d17ebcbfe8e3f9b6b56ad897c630481ca4fab7a1.zip |
mod_pubsub: Add the list of affiliations to reply
-rw-r--r-- | plugins/mod_pubsub/pubsub.lib.lua | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua index a43161c4..96360677 100644 --- a/plugins/mod_pubsub/pubsub.lib.lua +++ b/plugins/mod_pubsub/pubsub.lib.lua @@ -475,6 +475,10 @@ function handlers.owner_get_affiliations(origin, stanza, affiliations, service) :tag("pubsub", { xmlns = xmlns_pubsub_owner }) :tag("affiliations", { node = node }); + for jid, affiliation in pairs(node_obj.affiliations) do + reply:tag("affiliation", { jid = jid, affiliation = affiliation }):up(); + end + origin.send(reply); return true; end |