# HG changeset patch # User Kim Alvefur # Date 1535581074 -7200 # Node ID 3d12b4f41b23afa8edbc9519abc4a6eca6a9862f # Parent 711fea229e48d10d1c4e0bca4ac555ff5d8d17d8 prosodyctl: Also look for options that belong in global section under disabled hosts (fixes #1207) Thanks ivucica diff -r 711fea229e48 -r 3d12b4f41b23 prosodyctl --- a/prosodyctl Mon Aug 27 14:07:28 2018 +0100 +++ b/prosodyctl Thu Aug 30 00:17:54 2018 +0200 @@ -864,7 +864,7 @@ print(" "..tostring(deprecated_global_options)) ok = false; end - for host, options in enabled_hosts() do + for host, options in it.filter(function (h) return h ~= "*" end, pairs(configmanager.getconfig())) do local host_options = set.new(it.to_array(it.keys(options))); local misplaced_options = set.intersection(host_options, known_global_options); for name in pairs(options) do @@ -884,6 +884,9 @@ print(""); print(" You need to move the following option"..(n>1 and "s" or "")..": "..table.concat(it.to_array(misplaced_options), ", ")); end + end + for host, options in enabled_hosts() do + local host_options = set.new(it.to_array(it.keys(options))); local subdomain = host:match("^[^.]+"); if not(host_options:contains("component_module")) and (subdomain == "jabber" or subdomain == "xmpp" or subdomain == "chat" or subdomain == "im") then