Add debug statements for finding the source of #419

This commit is contained in:
games647
2016-05-11 16:55:22 +02:00
parent 3f5154e3c7
commit 4bad04b160
3 changed files with 17 additions and 0 deletions
@@ -1,5 +1,7 @@
package fr.xephi.authme.cache.auth;
import fr.xephi.authme.ConsoleLogger;
import java.util.concurrent.ConcurrentHashMap;
/**
@@ -22,6 +24,7 @@ public class PlayerCache {
if (singleton == null) {
singleton = new PlayerCache();
}
return singleton;
}
@@ -31,6 +34,7 @@ public class PlayerCache {
* @param auth PlayerAuth
*/
public void addPlayer(PlayerAuth auth) {
ConsoleLogger.debug("ADDED PLAYER TO CACHE " + auth.getNickname());
cache.put(auth.getNickname().toLowerCase(), auth);
}
@@ -40,6 +44,7 @@ public class PlayerCache {
* @param auth PlayerAuth
*/
public void updatePlayer(PlayerAuth auth) {
ConsoleLogger.debug("UPDATE PLAYER " + auth.getNickname());
cache.put(auth.getNickname(), auth);
}
@@ -49,6 +54,7 @@ public class PlayerCache {
* @param user String
*/
public void removePlayer(String user) {
ConsoleLogger.debug("REMOVE PLAYER " + user);
cache.remove(user.toLowerCase());
}