Mercurial > prosody-modules
comparison mod_compat_muc_admin/mod_compat_muc_admin.lua @ 731:15a8b717597b
mod_compat_muc_admin: added missing import (thanke MattJ)
| author | Marco Cirillo <maranda@lightwitch.org> |
|---|---|
| date | Sat, 30 Jun 2012 23:01:29 +0000 |
| parents | c9084b4c14f0 |
| children |
comparison
equal
deleted
inserted
replaced
| 730:274bb1a96122 | 731:15a8b717597b |
|---|---|
| 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) |
