diff options
author | Kim Alvefur <zash@zash.se> | 2018-05-26 14:44:50 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2018-05-26 14:44:50 +0200 |
commit | 154c2747e767a2bd8309ed7fde858752f69a360c (patch) | |
tree | 234c25f11b78e8d20cd913eec583b597773a68ec /plugins/muc/description.lib.lua | |
parent | dedba5658ee72c68a5c94b6d7093fe4d77ebbcdc (diff) | |
download | prosody-154c2747e767a2bd8309ed7fde858752f69a360c.tar.gz prosody-154c2747e767a2bd8309ed7fde858752f69a360c.zip |
MUC: Use correct field name for description in disco#info (fixes #1148)
Introduced in c3254827698d
Diffstat (limited to 'plugins/muc/description.lib.lua')
-rw-r--r-- | plugins/muc/description.lib.lua | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/plugins/muc/description.lib.lua b/plugins/muc/description.lib.lua index d4bc1a71..d9e02724 100644 --- a/plugins/muc/description.lib.lua +++ b/plugins/muc/description.lib.lua @@ -18,6 +18,14 @@ local function set_description(room, description) return true; end +local function add_disco_form(event) + table.insert(event.form, { + name = "muc#roominfo_description"; + label = "Description"; + value = get_description(event.room) or ""; + }); +end + local function add_form_option(event) table.insert(event.form, { name = "muc#roomconfig_roomdesc"; @@ -26,7 +34,7 @@ local function add_form_option(event) value = get_description(event.room) or ""; }); end -module:hook("muc-disco#info", add_form_option); +module:hook("muc-disco#info", add_disco_form); module:hook("muc-config-form", add_form_option, 100-2); module:hook("muc-config-submitted/muc#roomconfig_roomdesc", function(event) |