Mercurial > prosody-hg
comparison core/componentmanager.lua @ 3462:cf72ef3c9009
componentmanager: Support the 'disallow_s2s' option for components too (thanks darkhopatomopus)
| author | Matthew Wild <mwild1@gmail.com> |
|---|---|
| date | Mon, 23 Aug 2010 01:18:52 +0100 |
| parents | 6cb971a31397 |
| children | 011566d72331 |
comparison
equal
deleted
inserted
replaced
| 3461:447634564356 | 3462:cf72ef3c9009 |
|---|---|
| 40 | 40 |
| 41 for host, host_config in pairs(defined_hosts) do | 41 for host, host_config in pairs(defined_hosts) do |
| 42 if host ~= "*" and ((host_config.core.enabled == nil or host_config.core.enabled) and type(host_config.core.component_module) == "string") then | 42 if host ~= "*" and ((host_config.core.enabled == nil or host_config.core.enabled) and type(host_config.core.component_module) == "string") then |
| 43 hosts[host] = create_component(host); | 43 hosts[host] = create_component(host); |
| 44 hosts[host].connected = false; | 44 hosts[host].connected = false; |
| 45 disallow_s2s = configmanager.get(host, "core", "disallow_s2s"); | |
| 45 components[host] = default_component_handler; | 46 components[host] = default_component_handler; |
| 46 local ok, err = modulemanager.load(host, host_config.core.component_module); | 47 local ok, err = modulemanager.load(host, host_config.core.component_module); |
| 47 if not ok then | 48 if not ok then |
| 48 log("error", "Error loading %s component %s: %s", tostring(host_config.core.component_module), tostring(host), tostring(err)); | 49 log("error", "Error loading %s component %s: %s", tostring(host_config.core.component_module), tostring(host), tostring(err)); |
| 49 else | 50 else |
