# HG changeset patch # User Kim Alvefur # Date 1530176184 -7200 # Node ID f12cc1d7aa653ae49b6d178a8b07603f8262cd61 # Parent 1c29253763152ab9d7f5830ad5594c09f92d0730 prosodyctl: Warn if attempting to run an unknown check (fixes #1161) diff -r 1c2925376315 -r f12cc1d7aa65 prosodyctl --- a/prosodyctl Fri Jun 22 13:20:38 2018 +0100 +++ b/prosodyctl Thu Jun 28 10:56:24 2018 +0200 @@ -989,6 +989,10 @@ local ok = true; local function disabled_hosts(host, conf) return host ~= "*" and conf.enabled ~= false; end local function enabled_hosts() return it.filter(disabled_hosts, pairs(config.getconfig())); end + if not (what == nil or what == "disabled" or what == "config" or what == "dns" or what == "certs") then + show_warning("Don't know how to check '%s'. Try one of 'config', 'dns', 'certs' or 'disabled'.", what); + return 1; + end if not what or what == "disabled" then local disabled_hosts = set.new(); for host, host_options in it.filter("*", pairs(config.getconfig())) do