diff mod_block_outgoing/mod_block_outgoing.lua @ 2006:cb810a2bca47

mod_block_outgoing: Allow stanzas to user's login host (e.g. disco queries)
author Matthew Wild <mwild1@gmail.com>
date Wed, 13 Jan 2016 16:10:27 +0000
parents c769ed3e5b2b
children dc1299ca0185
line wrap: on
line diff
--- a/mod_block_outgoing/mod_block_outgoing.lua	Wed Jan 13 14:56:19 2016 +0000
+++ b/mod_block_outgoing/mod_block_outgoing.lua	Wed Jan 13 16:10:27 2016 +0000
@@ -12,7 +12,7 @@
 local function block_stanza(event)
 	local stanza = event.stanza;
 	local from_jid = jid_bare(stanza.attr.from);
-	if stanza.attr.to == nil or is_admin(from_jid, module.host) then
+	if stanza.attr.to == nil or stanza.attr.to == module.host or is_admin(from_jid, module.host) then
 		return;
 	end
 	if block_all or block_users:contains(from_jid)  then