aboutsummaryrefslogtreecommitdiffstats
path: root/util/dataforms.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2018-08-03 21:05:48 +0200
committerKim Alvefur <zash@zash.se>2018-08-03 21:05:48 +0200
commit154e32c79d7e06de13716dadf5d26dbc3fca49ea (patch)
treebce0c469dab12315802438d68b082fbbf35f7e24 /util/dataforms.lua
parentb5f0ad00c668b624ed596e659e68c79773a540ea (diff)
downloadprosody-154e32c79d7e06de13716dadf5d26dbc3fca49ea.tar.gz
prosody-154e32c79d7e06de13716dadf5d26dbc3fca49ea.zip
util.dataforms: Only include options in 'form' type forms
Options should not be needed in other types of forms.
Diffstat (limited to 'util/dataforms.lua')
-rw-r--r--util/dataforms.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/util/dataforms.lua b/util/dataforms.lua
index 06b74886..30a1dde7 100644
--- a/util/dataforms.lua
+++ b/util/dataforms.lua
@@ -50,7 +50,7 @@ function form_t.form(layout, data, formtype)
value = field.value;
end
- if formtype ~= "result" and field.options then
+ if formtype == "form" and field.options then
local defaults = {};
for _, val in ipairs(field.options) do
if type(val) == "table" then