Commit 954f816e authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Ignore subscribed presences of unknown users. JM-903

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk@6246 b35dd754-fafc-0310-a699-88a17e54d16e
parent 49f4b6bb
...@@ -237,10 +237,11 @@ public class PresenceSubscribeHandler extends BasicModule implements ChannelHand ...@@ -237,10 +237,11 @@ public class PresenceSubscribeHandler extends BasicModule implements ChannelHand
item = roster.getRosterItem(target); item = roster.getRosterItem(target);
} }
else { else {
if (Presence.Type.unsubscribed == type || Presence.Type.unsubscribe == type) { if (Presence.Type.unsubscribed == type || Presence.Type.unsubscribe == type ||
Presence.Type.subscribed == type) {
// Do not create a roster item when processing a confirmation of // Do not create a roster item when processing a confirmation of
// an unsubscription or receiving an unsubscription request from // an unsubscription or receiving an unsubscription request or a
// an unknown user // subscription approval from an unknown user
return false; return false;
} }
item = roster.createRosterItem(target, false, true); item = roster.createRosterItem(target, false, true);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment