Software / code / prosody
Comparison
prosodyctl @ 8948:3be8799263f3
Merge 0.10->trunk
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Thu, 28 Jun 2018 11:05:00 +0200 |
| parent | 8924:8fe98e365ab8 |
| parent | 8947:f12cc1d7aa65 |
| child | 9231:3d12b4f41b23 |
comparison
equal
deleted
inserted
replaced
| 8946:3a095233e178 | 8948:3be8799263f3 |
|---|---|
| 777 local set = require "util.set"; | 777 local set = require "util.set"; |
| 778 local it = require "util.iterators"; | 778 local it = require "util.iterators"; |
| 779 local ok = true; | 779 local ok = true; |
| 780 local function disabled_hosts(host, conf) return host ~= "*" and conf.enabled ~= false; end | 780 local function disabled_hosts(host, conf) return host ~= "*" and conf.enabled ~= false; end |
| 781 local function enabled_hosts() return it.filter(disabled_hosts, pairs(configmanager.getconfig())); end | 781 local function enabled_hosts() return it.filter(disabled_hosts, pairs(configmanager.getconfig())); end |
| 782 if not (what == nil or what == "disabled" or what == "config" or what == "dns" or what == "certs") then | |
| 783 show_warning("Don't know how to check '%s'. Try one of 'config', 'dns', 'certs' or 'disabled'.", what); | |
| 784 return 1; | |
| 785 end | |
| 782 if not what or what == "disabled" then | 786 if not what or what == "disabled" then |
| 783 local disabled_hosts_set = set.new(); | 787 local disabled_hosts_set = set.new(); |
| 784 for host, host_options in it.filter("*", pairs(configmanager.getconfig())) do | 788 for host, host_options in it.filter("*", pairs(configmanager.getconfig())) do |
| 785 if host_options.enabled == false then | 789 if host_options.enabled == false then |
| 786 disabled_hosts_set:add(host); | 790 disabled_hosts_set:add(host); |