diff options
-rw-r--r-- | plugins/mod_admin_shell.lua | 2 | ||||
-rw-r--r-- | util/error.lua | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/plugins/mod_admin_shell.lua b/plugins/mod_admin_shell.lua index 217a827b..91104cd6 100644 --- a/plugins/mod_admin_shell.lua +++ b/plugins/mod_admin_shell.lua @@ -903,7 +903,7 @@ available_columns = { width = math.max(#"Expired", #"Self-signed", #"Untrusted", #"Mismatched", #"Unknown"); mapper = function(cert_status, session) if cert_status then return capitalize(cert_status); end - if session.cert_chain_status == "Invalid" then + if session.cert_chain_status == "invalid" then local cert_errors = set.new(session.cert_chain_errors[1]); if cert_errors:contains("certificate has expired") then return "Expired"; diff --git a/util/error.lua b/util/error.lua index da6d938c..64c742ae 100644 --- a/util/error.lua +++ b/util/error.lua @@ -141,7 +141,7 @@ local function from_stanza(stanza, context, source) local error_tag = stanza:get_child("error"); context = context or {}; context.stanza = stanza; - context.by = error_tag.attr.by or stanza.attr.from; + context.by = error_tag and error_tag.attr.by or stanza.attr.from; local uri; if condition == "gone" or condition == "redirect" then |