Mon, 27 Sep 2010 19:00:11 +0500
MUC: Fixed traceback on presence errors lacking a condition.
plugins/muc/muc.lib.lua | file | annotate | diff | comparison | revisions |
--- a/plugins/muc/muc.lib.lua Tue Sep 21 18:28:06 2010 +0500 +++ b/plugins/muc/muc.lib.lua Mon Sep 27 19:00:11 2010 +0500 @@ -243,7 +243,7 @@ local function build_unavailable_presence_from_error(stanza) local type, condition, text = stanza:get_error(); - local error_message = "Kicked: "..condition:gsub("%-", " "); + local error_message = "Kicked: "..(condition and condition:gsub("%-", " ") or "presence error"); if text then error_message = error_message..": "..text; end