projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cfa86a6
)
util.helpers: Helper helpers to log host events
author
Matthew Wild
<mwild1@gmail.com>
Wed, 3 Apr 2013 12:39:00 +0000
(13:39 +0100)
committer
Matthew Wild
<mwild1@gmail.com>
Wed, 3 Apr 2013 12:39:00 +0000
(13:39 +0100)
util/helpers.lua
patch
|
blob
|
history
diff --git
a/util/helpers.lua
b/util/helpers.lua
index 6103a319fbc2cd099d28472c195e378d1a3f2d60..08b86a7c0907ee462af619f11e982dc73afae6ef 100644
(file)
--- a/
util/helpers.lua
+++ b/
util/helpers.lua
@@
-14,6
+14,14
@@
module("helpers", package.seeall);
local log = require "util.logger".init("util.debug");
+function log_host_events(host)
+ return log_events(prosody.hosts[host].events, host);
+end
+
+function revert_log_host_events(host)
+ return revert_log_events(prosody.hosts[host].events);
+end
+
function log_events(events, name, logger)
local f = events.fire_event;
if not f then