Can be isEmpty

This commit is contained in:
vraskulin 2017-02-09 17:44:14 +03:00
parent 433b08238f
commit 7cf4ca3cae

View file

@ -124,7 +124,7 @@ public class ChatManager {
if (messageType != MessageType.GAME) {
User user = UserManager.getInstance().getUserByName(userName);
if (message != null && userName != null && !userName.equals("")) {
if (message != null && userName != null && !userName.isEmpty()) {
if (message.equals(userMessages.get(userName))) {
// prevent identical messages