aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mod_presence.lua
diff options
context:
space:
mode:
authorRobert Hoelz <rob@hoelz.ro>2010-12-09 12:23:37 -0600
committerRobert Hoelz <rob@hoelz.ro>2010-12-09 12:23:37 -0600
commitde4b6ceb3376974f56d80129848d5fd0c0009bd7 (patch)
tree97189181cdd2630cbe40ac75c03ce17f7244c448 /plugins/mod_presence.lua
parent109b7a0e12503d943574cf1150a92f903146a2ac (diff)
downloadprosody-de4b6ceb3376974f56d80129848d5fd0c0009bd7.tar.gz
prosody-de4b6ceb3376974f56d80129848d5fd0c0009bd7.zip
core.offlinemanager, mod_message, mod_presence: Removed core.offlinemanager in favor of mod_offline.
Diffstat (limited to 'plugins/mod_presence.lua')
-rw-r--r--plugins/mod_presence.lua11
1 files changed, 3 insertions, 8 deletions
diff --git a/plugins/mod_presence.lua b/plugins/mod_presence.lua
index 65abe665..933aac62 100644
--- a/plugins/mod_presence.lua
+++ b/plugins/mod_presence.lua
@@ -22,7 +22,6 @@ local NULL = {};
local rostermanager = require "core.rostermanager";
local sessionmanager = require "core.sessionmanager";
-local offlinemanager = require "core.offlinemanager";
local function select_top_resources(user)
local priority = 0;
@@ -116,13 +115,9 @@ function handle_normal_presence(origin, stanza)
end
if priority >= 0 then
- local offline = offlinemanager.load(node, host);
- if offline then
- for _, msg in ipairs(offline) do
- origin.send(msg); -- FIXME do we need to modify to/from in any way?
- end
- offlinemanager.deleteAll(node, host);
- end
+ local event = { origin = origin }
+ module:fire_event('message/offline/broadcast', event);
+ module:fire_event('message/offline/delete', event);
end
end
if stanza.attr.type == "unavailable" then