Software /
code /
prosody
Changeset
3857:57d88113e3a4
mod_pep: Handle the case where local contacts send directed presence with caps hash.
author | Waqas Hussain <waqas20@gmail.com> |
---|---|
date | Sun, 12 Dec 2010 06:35:53 +0500 |
parents | 3856:2cb50432bc9a |
children | 3858:b76ac6c3a037 |
files | plugins/mod_pep.lua |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/mod_pep.lua Sun Dec 12 06:29:19 2010 +0500 +++ b/plugins/mod_pep.lua Sun Dec 12 06:35:53 2010 +0500 @@ -134,7 +134,8 @@ publish_all(user, recipient, origin); else recipients[user][recipient] = hash; - if self or origin.type ~= "c2s" then + local from_bare = origin.username.."@"..origin.host; + if self or origin.type ~= "c2s" or (recipients[from_bare] and recipients[from_bare][origin.full_jid]) ~= hash then origin.send( st.stanza("iq", {from=stanza.attr.to, to=stanza.attr.from, id="disco", type="get"}) :query("http://jabber.org/protocol/disco#info")