diff options
-rw-r--r-- | plugins/mod_component.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/plugins/mod_component.lua b/plugins/mod_component.lua index f4b0d51c..90a2f3b1 100644 --- a/plugins/mod_component.lua +++ b/plugins/mod_component.lua @@ -214,4 +214,11 @@ end connlisteners.register('component', component_listener); -module:add_event_hook("server-starting", function () connlisteners.start("component"); end); +module:add_event_hook("server-started", + function () + if net_activate_ports then + net_activate_ports("component_ports", "component", {5437}, "tcp"); + else + error("No net_activate_ports: Using an incompatible version of Prosody?"); + end + end); |