mirror of
https://github.com/igniterealtime/Spark.git
synced 2025-12-01 12:27:58 +00:00
groupchat modifications:
- change room association of users - added more icons for roles (owner,admin,member) - changed old role icons added new localized strings: menuitem.revoke.member = Revoke Membership menuitem.revoke.admin = Revoke Admin menuitem.revoke.owner = Revoke Ownership menuitem.grant.member = Grant Membership menuitem.grant.admin = Grant Admin menutiem.grant.owner = Grant Ownership menuitem.affiliation = Affiliation git-svn-id: http://svn.igniterealtime.org/svn/repos/spark/trunk@12247 b35dd754-fafc-0310-a699-88a17e54d16e
This commit is contained in:
committed by
wolf.posdorfer
parent
d6add8020f
commit
4052a30662
@ -148,6 +148,22 @@ public class UserManager {
|
||||
}
|
||||
return false;
|
||||
}
|
||||
/**
|
||||
* Checks if the Occupant is a Member in this Room<br>
|
||||
* <b>admins and owners are also members!!!</b>
|
||||
* @param occupant
|
||||
* @return true if member, else false
|
||||
*/
|
||||
public boolean isMember(Occupant occupant) {
|
||||
if (occupant != null) {
|
||||
String affiliation = occupant.getAffiliation();
|
||||
if ("member".equals(affiliation) || affiliation.equals("owner")
|
||||
|| affiliation.equals("admin")) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks to see if the Occupant is a moderator.
|
||||
|
||||
Reference in New Issue
Block a user