Mercurial > prosody-hg
comparison plugins/muc/description.lib.lua @ 7401:e16b3fd0bd80
MUC: Assign priorities to config form hooks so they have a consistent order on each start
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Tue, 19 Apr 2016 20:31:39 +0200 |
| parents | ca31d3271cf8 |
| children | 6dd7fea941f6 |
comparison
equal
deleted
inserted
replaced
| 7400:f1ff321178d4 | 7401:e16b3fd0bd80 |
|---|---|
| 25 label = "Description"; | 25 label = "Description"; |
| 26 value = get_description(event.room) or ""; | 26 value = get_description(event.room) or ""; |
| 27 }); | 27 }); |
| 28 end | 28 end |
| 29 module:hook("muc-disco#info", add_form_option); | 29 module:hook("muc-disco#info", add_form_option); |
| 30 module:hook("muc-config-form", add_form_option); | 30 module:hook("muc-config-form", add_form_option, 100-2); |
| 31 | 31 |
| 32 module:hook("muc-config-submitted/muc#roomconfig_roomdesc", function(event) | 32 module:hook("muc-config-submitted/muc#roomconfig_roomdesc", function(event) |
| 33 if set_description(event.room, event.value) then | 33 if set_description(event.room, event.value) then |
| 34 event.status_codes["104"] = true; | 34 event.status_codes["104"] = true; |
| 35 end | 35 end |
