aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2009-02-04 18:53:23 +0000
committerMatthew Wild <mwild1@gmail.com>2009-02-04 18:53:23 +0000
commit039df2c7e32288235b00224098994aea24b3787c (patch)
treeb1b1137b9ef16e1acf187604de23957358227416
parent9dc169d931f95a1da585c9018c4c186f51aa948a (diff)
downloadprosody-039df2c7e32288235b00224098994aea24b3787c.tar.gz
prosody-039df2c7e32288235b00224098994aea24b3787c.zip
Fix for never checking if the first module for a host is already loaded (affects global modules)
-rw-r--r--core/modulemanager.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/modulemanager.lua b/core/modulemanager.lua
index b7158e31..12cf9ce8 100644
--- a/core/modulemanager.lua
+++ b/core/modulemanager.lua
@@ -90,7 +90,9 @@ function load(host, module_name, config)
if not modulemap[host] then
modulemap[host] = {};
- elseif modulemap[host][module_name] then
+ end
+
+ if modulemap[host][module_name] then
log("warn", "%s is already loaded for %s, so not loading again", module_name, host);
return nil, "module-already-loaded";
elseif modulemap["*"][module_name] then