Software / code / prosody
Comparison
plugins/muc/mod_muc.lua @ 5580:db5d1a350cc7
mod_muc: Refactor config form handling, and allow for clients to submit incomplete forms. Fixes #246
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Thu, 16 May 2013 14:17:25 +0100 |
| parent | 5577:8b09b0d068d4 |
| child | 5659:9f9de8078164 |
comparison
equal
deleted
inserted
replaced
| 5579:e449e6342e36 | 5580:db5d1a350cc7 |
|---|---|
| 113 :tag("feature", {var="http://jabber.org/protocol/muc"}); -- TODO cache disco reply | 113 :tag("feature", {var="http://jabber.org/protocol/muc"}); -- TODO cache disco reply |
| 114 end | 114 end |
| 115 local function get_disco_items(stanza) | 115 local function get_disco_items(stanza) |
| 116 local reply = st.iq({type='result', id=stanza.attr.id, from=muc_host, to=stanza.attr.from}):query("http://jabber.org/protocol/disco#items"); | 116 local reply = st.iq({type='result', id=stanza.attr.id, from=muc_host, to=stanza.attr.from}):query("http://jabber.org/protocol/disco#items"); |
| 117 for jid, room in pairs(rooms) do | 117 for jid, room in pairs(rooms) do |
| 118 if not room:is_hidden() then | 118 if not room:get_hidden() then |
| 119 reply:tag("item", {jid=jid, name=room:get_name()}):up(); | 119 reply:tag("item", {jid=jid, name=room:get_name()}):up(); |
| 120 end | 120 end |
| 121 end | 121 end |
| 122 return reply; -- TODO cache disco reply | 122 return reply; -- TODO cache disco reply |
| 123 end | 123 end |