aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2012-04-29 19:36:11 +0100
committerMatthew Wild <mwild1@gmail.com>2012-04-29 19:36:11 +0100
commit945e41b4e0ac65ea94d59a1be3a71718e28850bc (patch)
treee51c6685382af3ef78605188b1f9d279748ac844 /core
parenta2518c8d453a59dd63aee8e9f7c97d9c93da5429 (diff)
downloadprosody-945e41b4e0ac65ea94d59a1be3a71718e28850bc.tar.gz
prosody-945e41b4e0ac65ea94d59a1be3a71718e28850bc.zip
modulemanager: Hide deprecation warning for modules loaded on '*' directly (e.g. prosodyctl mod_<command>) (thanks Zash)
Diffstat (limited to 'core')
-rw-r--r--core/modulemanager.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/modulemanager.lua b/core/modulemanager.lua
index 90116166..461bff5c 100644
--- a/core/modulemanager.lua
+++ b/core/modulemanager.lua
@@ -180,7 +180,9 @@ local function do_load_module(host, module_name)
if api_instance.host == "*" then
if not api_instance.global then -- COMPAT w/pre-0.9
- log("warn", "mod_%s: Setting module.host = '*' deprecated, call module:set_global() instead", module_name);
+ if host ~= "*" then
+ log("warn", "mod_%s: Setting module.host = '*' deprecated, call module:set_global() instead", module_name);
+ end
api_instance:set_global();
end
modulemap[host][module_name] = nil;