Commit 6d4a7cfb authored by Gaston Dombiak's avatar Gaston Dombiak Committed by gato

Fixed NPE when username is null. JM-385

git-svn-id: http://svn.igniterealtime.org/svn/repos/messenger/trunk@2797 b35dd754-fafc-0310-a699-88a17e54d16e
parent 77277290
......@@ -188,7 +188,11 @@ public class Group implements Cacheable {
* @return true if the provided username belongs to a user of the group.
*/
public boolean isUser(String username) {
return members.contains(username) || administrators.contains(username);
if (username != null) {
return members.contains(username) || administrators.contains(username);
} else {
return false;
}
}
public int getCachedSize() {
......
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