# HG changeset patch # User Waqas Hussain # Date 1260403652 -18000 # Node ID a7ef564271a5483f8e52148d329779152947e4f2 # Parent f8d002090ceadd9be989d18478063eead3d16a4a net_activate_ports: Use the default config option 'ports' when no option is specified. diff -r f8d002090cea -r a7ef564271a5 prosody --- a/prosody Thu Dec 10 05:04:09 2009 +0500 +++ b/prosody Thu Dec 10 05:07:32 2009 +0500 @@ -193,8 +193,9 @@ local cl = require "net.connlisteners"; function prosody.net_activate_ports(option, listener, default, conntype) conntype = conntype or (global_ssl_ctx and "tls") or "tcp"; + option = option and option.."_ports" or "ports"; if not cl.get(listener) then return; end - local ports = config.get("*", "core", option.."_ports") or default; + local ports = config.get("*", "core", option) or default; if type(ports) == "number" then ports = {ports} end; if type(ports) ~= "table" then