Software /
code /
prosody
Changeset
10663:fd651ba2317f
mod_admin_telnet: Allow passing list of hosts to http:list()
Lets you select what hosts to list http services on. In particular, this
enables listing global http services, which was not possible before.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 24 Feb 2020 18:38:09 +0100 |
parents | 10662:46373b97e648 |
children | 10664:c2b79b44ded7 |
files | plugins/mod_admin_telnet.lua |
diffstat | 1 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_admin_telnet.lua Mon Feb 24 14:16:45 2020 +0100 +++ b/plugins/mod_admin_telnet.lua Mon Feb 24 18:38:09 2020 +0100 @@ -1241,10 +1241,10 @@ def_env.http = {}; -function def_env.http:list() +function def_env.http:list(hosts) local print = self.session.print; - for host in pairs(prosody.hosts) do + for host in get_hosts_set(hosts) do local http_apps = modulemanager.get_items("http-provider", host); if #http_apps > 0 then local http_host = module:context(host):get_option_string("http_host");