aboutsummaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2009-07-09 14:37:04 +0100
committerMatthew Wild <mwild1@gmail.com>2009-07-09 14:37:04 +0100
commitb20127b81a64bf5432ed21d7464b53c2995b8af2 (patch)
tree4fda08f706d1078bfbb13fa7e6ba6bd8b6f79720 /core
parent455e77f21d657b34d8fa6910fb2c0c32d2ea4085 (diff)
downloadprosody-b20127b81a64bf5432ed21d7464b53c2995b8af2.tar.gz
prosody-b20127b81a64bf5432ed21d7464b53c2995b8af2.zip
modulemanager: Small code improvement, move autoloaded modules list to the top of the file
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 cc9e2686..56f8793a 100644
--- a/core/modulemanager.lua
+++ b/core/modulemanager.lua
@@ -33,6 +33,8 @@ local rawget = rawget;
local error = error;
local tostring = tostring;
+local autoload_modules = {"presence", "message", "iq"};
+
-- We need this to let modules access the real global namespace
local _G = _G;
@@ -70,7 +72,7 @@ function load_modules_for_host(host)
disabled_set[module] = true;
end
end
- for _, module in ipairs({"presence", "message", "iq"}) do
+ for _, module in ipairs(autoload_modules) do
if not disabled_set[module] then
load(host, module);
end