aboutsummaryrefslogtreecommitdiffstats
path: root/core/modulemanager.lua
diff options
context:
space:
mode:
authorWaqas Hussain <waqas20@gmail.com>2009-10-17 23:48:30 +0500
committerWaqas Hussain <waqas20@gmail.com>2009-10-17 23:48:30 +0500
commitbf059aa4558801f219c1f8ba91e070a350b3c946 (patch)
tree4bea19750be9a0883aeb582d813620cd662824b5 /core/modulemanager.lua
parent2970ea37eb72ceb4005af824417242871eccb825 (diff)
downloadprosody-bf059aa4558801f219c1f8ba91e070a350b3c946.tar.gz
prosody-bf059aa4558801f219c1f8ba91e070a350b3c946.zip
modulemanager: Slightly rearranged code for more robust unloading of modules.
Diffstat (limited to 'core/modulemanager.lua')
-rw-r--r--core/modulemanager.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/modulemanager.lua b/core/modulemanager.lua
index 312ca738..9e93ffba 100644
--- a/core/modulemanager.lua
+++ b/core/modulemanager.lua
@@ -170,7 +170,6 @@ function unload(host, name, ...)
log("warn", "Non-fatal error unloading module '%s' on '%s': %s", name, host, err);
end
end
- modulemap[host][name] = nil;
local params = handler_table:get(host, name); -- , {module.host, origin_type, tag, xmlns}
for _, param in pairs(params or NULL) do
local handlers = stanza_handlers:get(param[1], param[2], param[3], param[4]);
@@ -187,6 +186,7 @@ function unload(host, name, ...)
end
end
hooks:remove(host, name);
+ modulemap[host][name] = nil;
return true;
end