Software / code / prosody
Comparison
prosodyctl @ 7080:6946c3d5645f
prosodyctl check: Fix traceback if the global modules_enabled is unset
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Tue, 12 Jan 2016 01:13:57 +0100 |
| parent | 7065:4fc3c008976f |
| child | 7082:8b590fc77d91 |
comparison
equal
deleted
inserted
replaced
| 7079:f094683ae6eb | 7080:6946c3d5645f |
|---|---|
| 1078 if target_hosts:contains("localhost") then | 1078 if target_hosts:contains("localhost") then |
| 1079 print(" Target 'localhost' cannot be accessed from other servers"); | 1079 print(" Target 'localhost' cannot be accessed from other servers"); |
| 1080 target_hosts:remove("localhost"); | 1080 target_hosts:remove("localhost"); |
| 1081 end | 1081 end |
| 1082 | 1082 |
| 1083 local modules = set.new(it.to_array(it.values(host_options.modules_enabled))) | 1083 local modules = set.new(it.to_array(it.values(host_options.modules_enabled or {}))) |
| 1084 + set.new(it.to_array(it.values(config.get("*", "modules_enabled")))) | 1084 + set.new(it.to_array(it.values(config.get("*", "modules_enabled") or {}))) |
| 1085 + set.new({ config.get(host, "component_module") }); | 1085 + set.new({ config.get(host, "component_module") }); |
| 1086 | 1086 |
| 1087 if modules:contains("proxy65") then | 1087 if modules:contains("proxy65") then |
| 1088 local proxy65_target = config.get(host, "proxy65_address") or host; | 1088 local proxy65_target = config.get(host, "proxy65_address") or host; |
| 1089 local A, AAAA = dns.lookup(idna.to_ascii(proxy65_target), "A"), dns.lookup(idna.to_ascii(proxy65_target), "AAAA"); | 1089 local A, AAAA = dns.lookup(idna.to_ascii(proxy65_target), "A"), dns.lookup(idna.to_ascii(proxy65_target), "AAAA"); |