Mercurial > prosody-modules
comparison mod_muc_log_http/muc_log_http/mod_muc_log_http.lua @ 265:8cd2fab3135a
mod_muc_log_http: Updated to use the new events API.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Sat, 16 Oct 2010 08:09:48 +0500 |
parents | 07c17b60229a |
children | 845a59c99b4d |
comparison
equal
deleted
inserted
replaced
264:07c17b60229a | 265:8cd2fab3135a |
---|---|
825 function module.unload() | 825 function module.unload() |
826 muc_hosts = nil; | 826 muc_hosts = nil; |
827 module:log("debug", "unloaded mod_muc_log_http"); | 827 module:log("debug", "unloaded mod_muc_log_http"); |
828 end | 828 end |
829 | 829 |
830 module:add_event_hook("component-activated", function(component, config) | 830 module:hook("component-activated", function(component, config) |
831 if config.core and config.core.modules_enabled then | 831 if config.core and config.core.modules_enabled then |
832 for _,mod in ipairs(config.core.modules_enabled) do | 832 for _,mod in ipairs(config.core.modules_enabled) do |
833 if(mod == "muc_log") then | 833 if(mod == "muc_log") then |
834 module:log("debug", "component: %s", tostring(component)); | 834 module:log("debug", "component: %s", tostring(component)); |
835 muc_hosts[component] = true; | 835 muc_hosts[component] = true; |