--- a/plugins/mod_blocklist.lua Sat Oct 25 14:45:11 2014 +0200
+++ b/plugins/mod_blocklist.lua Sun Oct 26 16:29:50 2014 +0100
@@ -149,7 +149,9 @@
for jid, in_roster in pairs(new) do
if not blocklist[jid] and in_roster and sessions[username] then
for _, session in pairs(sessions[username].sessions) do
- module:send(st.presence({ type = "unavailable", to = jid, from = session.full_jid }));
+ if session.presence then
+ module:send(st.presence({ type = "unavailable", to = jid, from = session.full_jid }));
+ end
end
end
end