aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/muc/muc.lib.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2016-04-19 17:30:30 +0200
committerKim Alvefur <zash@zash.se>2016-04-19 17:30:30 +0200
commitee3e8bbd38974e1c5c788b06e9002af7eb02fed3 (patch)
tree3edde11b7c7da47a785d5aeb95b6b3510baf56d2 /plugins/muc/muc.lib.lua
parentacd12fcc61d2e0a23db0b938fbb0ed0215f86c11 (diff)
parent2bf3239f769a9ea49d8aa7cfaa62bc034ddc4773 (diff)
downloadprosody-ee3e8bbd38974e1c5c788b06e9002af7eb02fed3.tar.gz
prosody-ee3e8bbd38974e1c5c788b06e9002af7eb02fed3.zip
Merge 0.9->0.10
Diffstat (limited to 'plugins/muc/muc.lib.lua')
-rw-r--r--plugins/muc/muc.lib.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/plugins/muc/muc.lib.lua b/plugins/muc/muc.lib.lua
index 552b9e49..88ee43c1 100644
--- a/plugins/muc/muc.lib.lua
+++ b/plugins/muc/muc.lib.lua
@@ -681,6 +681,13 @@ function room_mt:process_form(origin, stanza)
if form.attr.type == "cancel" then origin.send(st.reply(stanza)); return; end
if form.attr.type ~= "submit" then origin.send(st.error_reply(stanza, "cancel", "bad-request", "Not a submitted form")); return; end
+ if form.tags[1] == nil then
+ -- instant room
+ if self.save then self:save(true); end
+ origin.send(st.reply(stanza));
+ return true;
+ end
+
local fields, errors, present = self:get_form_layout(stanza.attr.from):data(form);
if fields.FORM_TYPE ~= "http://jabber.org/protocol/muc#roomconfig" then
origin.send(st.error_reply(stanza, "cancel", "bad-request", "Form is not of type room configuration"));