# HG changeset patch # User Matthew Wild # Date 1277838285 -3600 # Node ID b651f8290e2727da35e21ce54df24c0ee88c3c0a # Parent 4448789c19ca9b57f872719b02fb99e7fac152eb mod_privacy: Treat stanzas with no 'to' address as going to the user's bare JID (thanks KSid) diff -r 4448789c19ca -r b651f8290e27 plugins/mod_privacy.lua --- a/plugins/mod_privacy.lua Thu Jun 24 04:16:09 2010 +0500 +++ b/plugins/mod_privacy.lua Tue Jun 29 20:04:45 2010 +0100 @@ -301,7 +301,7 @@ local origin, stanza = e.origin, e.stanza; local privacy_lists = datamanager.load(session.username, session.host, "privacy") or {}; local bare_jid = session.username.."@"..session.host; - local to = stanza.attr.to; + local to = stanza.attr.to or bare_jid; local from = stanza.attr.from; local is_to_user = bare_jid == jid_bare(to);