Software /
code /
prosody
Comparison
plugins/muc/whois.lib.lua @ 9112:e66d932eeb58
MUC: Provide options as options in config form (fixes traceback)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sat, 04 Aug 2018 23:12:52 +0200 |
parent | 9081:ce57c69a20e2 |
comparison
equal
deleted
inserted
replaced
9111:bc7473fb7ad3 | 9112:e66d932eeb58 |
---|---|
32 local whois = get_whois(event.room); | 32 local whois = get_whois(event.room); |
33 table.insert(event.form, { | 33 table.insert(event.form, { |
34 name = 'muc#roomconfig_whois', | 34 name = 'muc#roomconfig_whois', |
35 type = 'list-single', | 35 type = 'list-single', |
36 label = 'Addresses (JIDs) of room occupants may be viewed by:', | 36 label = 'Addresses (JIDs) of room occupants may be viewed by:', |
37 value = { | 37 options = { |
38 { value = 'moderators', label = 'Moderators only', default = whois == 'moderators' }, | 38 { value = 'moderators', label = 'Moderators only', default = whois == 'moderators' }, |
39 { value = 'anyone', label = 'Anyone', default = whois == 'anyone' } | 39 { value = 'anyone', label = 'Anyone', default = whois == 'anyone' } |
40 } | 40 } |
41 }); | 41 }); |
42 end, 80-4); | 42 end, 80-4); |