aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_pubsub/pubsub.lib.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-08-05 02:01:58 +0200
committerKim Alvefur <zash@zash.se>2018-08-05 02:01:58 +0200
commit9c75dbe8a8c7c575f0b91af37a0fcea71c883492 (patch)
treebd6eb565878d5ffe4cc7484e386b05af81137c02 /plugins/mod_pubsub/pubsub.lib.lua
parentcd89bab127659540f575afd0892e9d0bc51b49b6 (diff)
downloadprosody-9c75dbe8a8c7c575f0b91af37a0fcea71c883492.tar.gz
prosody-9c75dbe8a8c7c575f0b91af37a0fcea71c883492.zip
mod_pubsub: Rename variable subscription options form to improve readability
"options_form" ... options for what?
Diffstat (limited to 'plugins/mod_pubsub/pubsub.lib.lua')
-rw-r--r--plugins/mod_pubsub/pubsub.lib.lua8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/mod_pubsub/pubsub.lib.lua b/plugins/mod_pubsub/pubsub.lib.lua
index 7a8ca672..7c796c20 100644
--- a/plugins/mod_pubsub/pubsub.lib.lua
+++ b/plugins/mod_pubsub/pubsub.lib.lua
@@ -95,7 +95,7 @@ local node_config_form = dataform {
};
};
-local options_form = dataform {
+local subscribe_options_form = dataform {
{
type = "hidden";
name = "FORM_TYPE";
@@ -453,7 +453,7 @@ function handlers.set_subscribe(origin, stanza, subscribe, service)
end
local options_tag, options = stanza.tags[1]:get_child("options"), nil;
if options_tag then
- options = options_form:data(options_tag.tags[1]);
+ options = subscribe_options_form:data(options_tag.tags[1]);
end
local ok, ret = service:add_subscription(node, stanza.attr.from, jid, options);
local reply;
@@ -508,7 +508,7 @@ function handlers.get_options(origin, stanza, options, service)
origin.send(st.reply(stanza)
:tag("pubsub", { xmlns = xmlns_pubsub })
:tag("options", { node = node, jid = jid })
- :add_child(options_form:form(ret)));
+ :add_child(subscribe_options_form:form(ret)));
return true;
end
@@ -527,7 +527,7 @@ function handlers.set_options(origin, stanza, options, service)
origin.send(pubsub_error_reply(stanza, "not-subscribed"));
return true;
end
- local new_subopts, err = options_form:data(options.tags[1]);
+ local new_subopts, err = subscribe_options_form:data(options.tags[1]);
if not new_subopts then
origin.send(pubsub_error_reply(stanza, ret));
return true;