diff options
author | Kim Alvefur <zash@zash.se> | 2014-09-28 01:55:32 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2014-09-28 01:55:32 +0200 |
commit | bf317774d921f17f73443b59008970a68f756082 (patch) | |
tree | abf1f53031007cd82fde221fcf717e746efe290a /plugins/mod_pubsub/pubsub.lib.lua | |
parent | c5cf61eed2ccea6fd9eec0df19afbf2481c20349 (diff) | |
download | prosody-bf317774d921f17f73443b59008970a68f756082.tar.gz prosody-bf317774d921f17f73443b59008970a68f756082.zip |
mod_pubsub: Add support for requesting default node configuration
Diffstat (limited to 'plugins/mod_pubsub/pubsub.lib.lua')
-rw-r--r-- | plugins/mod_pubsub/pubsub.lib.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua index 075182a2..8a22fa69 100644 --- a/plugins/mod_pubsub/pubsub.lib.lua +++ b/plugins/mod_pubsub/pubsub.lib.lua @@ -271,4 +271,12 @@ function handlers.set_configure(origin, stanza, config, service) return origin.send(st.reply(stanza)); end +function handlers.get_default(origin, stanza, default, service) + local reply = st.reply(stanza) + :tag("pubsub", { xmlns = xmlns_pubsub_owner }) + :tag("configure", { node = node }) + :add_child(form:form(service.node_default_config)); + return origin.send(reply); +end + return _M; |