Commit 47088f1d authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Presence subscription is now of type both when each shared group can be seen...

Presence subscription is now of type both when each shared group can be seen by a group where the other user belongs. JM-985

git-svn-id: http://svn.igniterealtime.org/svn/repos/wildfire/trunk@7194 b35dd754-fafc-0310-a699-88a17e54d16e
parent 665dc693
...@@ -885,15 +885,15 @@ public class RosterManager extends BasicModule implements GroupEventListener, Us ...@@ -885,15 +885,15 @@ public class RosterManager extends BasicModule implements GroupEventListener, Us
otherGroupNames.contains(group.getName())) { otherGroupNames.contains(group.getName())) {
return true; return true;
} }
// Check if both shared groups have a common group that can see both shared groups and // Check if each shared group can be seen by a group where each user belongs
// the users belong to such group
Collection<Group> groupList = parseGroups(groupNames); Collection<Group> groupList = parseGroups(groupNames);
Collection<Group> otherGroupList = parseGroups(otherGroupNames); Collection<Group> otherGroupList = parseGroups(otherGroupNames);
for (Group groupName : groupList) { for (Group groupName : groupList) {
for (Group otherGroupName : otherGroupList) { if (groupName.isUser(otherUser)) {
if (groupName.equals(otherGroupName) && groupName.isUser(user) && for (Group otherGroupName : otherGroupList) {
otherGroupName.isUser(otherUser)) { if (otherGroupName.isUser(user)) {
return true; return 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