prosodyctl: Fix import of util.iterators
[prosody.git] / plugins / mod_proxy65.lua
index 155cb60dc44b11d344a1b861bba0b44f385a3988..b2f6f7035b9111ee36dfd801de38be8f8896339c 100644 (file)
@@ -91,7 +91,7 @@ function module.add_host(module)
        local host, name = module:get_host(), module:get_option_string("name", "SOCKS5 Bytestreams Service");
        
        local proxy_address = module:get_option("proxy65_address", host);
-       local proxy_port = module:get_option_number("proxy65_port", next(portmanager.get_active_services():search("proxy65", nil)[1]));
+       local proxy_port = module:get_option_number("proxy65_port", next(portmanager.get_active_services():search("proxy65", nil)[1] or {}));
        local proxy_acl = module:get_option("proxy65_acl");
 
        module:add_identity("proxy", "bytestreams", name);
@@ -173,4 +173,7 @@ end
 module:provides("net", {
        default_port = 5000;
        listener = listener;
+       multiplex = {
+               pattern = "^\5";
+       };
 });