Mercurial > prosody-modules
comparison mod_compat_muc_admin/mod_compat_muc_admin.lua @ 753:9d5731af2c27
Merge with Oliver Gerlich
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Fri, 27 Jul 2012 14:29:59 +0100 |
| parents | 15a8b717597b |
| children |
comparison
equal
deleted
inserted
replaced
| 752:9bbd99f2057a | 753:9d5731af2c27 |
|---|---|
| 21 ["remote-server-not-found"] = true; | 21 ["remote-server-not-found"] = true; |
| 22 ["remote-server-timeout"] = true; | 22 ["remote-server-timeout"] = true; |
| 23 ["service-unavailable"] = true; | 23 ["service-unavailable"] = true; |
| 24 ["malformed error"] = true; | 24 ["malformed error"] = true; |
| 25 }; | 25 }; |
| 26 local function get_error_condition(stanza) | |
| 27 local _, condition = stanza:get_error(); | |
| 28 return condition or "malformed error"; | |
| 29 end | |
| 26 local function is_kickable_error(stanza) | 30 local function is_kickable_error(stanza) |
| 27 local cond = get_error_condition(stanza); | 31 local cond = get_error_condition(stanza); |
| 28 return kickable_error_conditions[cond] and cond; | 32 return kickable_error_conditions[cond] and cond; |
| 29 end | 33 end |
| 30 local function build_unavailable_presence_from_error(stanza) | 34 local function build_unavailable_presence_from_error(stanza) |
