Software /
code /
prosody
Diff
core/hostmanager.lua @ 8251:cb2d86f4b511
hostmanager: Add support for 'disco_hidden' option to hide hosts from disco#items (thanks Ge0rG)
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Wed, 20 Sep 2017 14:42:21 +0100 |
parent | 6779:6236668da30a |
child | 8253:3a6f5b0f56f0 |
child | 8559:d5d746e4c453 |
line wrap: on
line diff
--- a/core/hostmanager.lua Mon Sep 18 18:35:01 2017 +0200 +++ b/core/hostmanager.lua Wed Sep 20 14:42:21 2017 +0100 @@ -100,7 +100,7 @@ host_session.type = "component"; end hosts[host] = host_session; - if not host:match("[@/]") then + if not host_config.disco_hidden and not host:match("[@/]") then disco_items:set(host:match("%.(.*)") or "*", host, host_config.name or true); end for option_name in pairs(host_config) do