diff options
author | Matthew Wild <mwild1@gmail.com> | 2010-02-18 16:46:07 +0000 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2010-02-18 16:46:07 +0000 |
commit | 80952e2cc9c13df0a8a9ea572326f82285b05141 (patch) | |
tree | 4cd0d2ec4c7c03553ce9ae55132d85802f2bced9 /core/modulemanager.lua | |
parent | 4aaa16aa23eb1fa887dd27e6286b05dd557054e5 (diff) | |
parent | f2a5185e0074e220759ccc35ca897d6d948cb219 (diff) | |
download | prosody-80952e2cc9c13df0a8a9ea572326f82285b05141.tar.gz prosody-80952e2cc9c13df0a8a9ea572326f82285b05141.zip |
Merge with 0.7
Diffstat (limited to 'core/modulemanager.lua')
-rw-r--r-- | core/modulemanager.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/modulemanager.lua b/core/modulemanager.lua index 6b2260f5..1174352b 100644 --- a/core/modulemanager.lua +++ b/core/modulemanager.lua @@ -158,7 +158,7 @@ function load(host, module_name, config) log("error", "Error initializing module '%s' on '%s': %s", module_name, host, err or "nil"); end if success then - hosts[host].events.fire_event("module-loaded", { module = module_name, host = host }); + (hosts[api_instance.host] or prosody).events.fire_event("module-loaded", { module = module_name, host = host }); return true; else -- load failed, unloading unload(api_instance.host, module_name); @@ -210,7 +210,7 @@ function unload(host, name, ...) end end modulemap[host][name] = nil; - hosts[host].events.fire_event("module-unloaded", { module = name, host = host }); + (hosts[host] or prosody).events.fire_event("module-unloaded", { module = name, host = host }); return true; end |