Encapsulate fields in main class; see #762 #655 #604

This commit is contained in:
Gnat008
2016-06-27 11:25:12 -04:00
parent 99704e7c29
commit 0c96a3113b
10 changed files with 84 additions and 37 deletions
@@ -94,7 +94,7 @@ public class AsynchronousQuit implements AsynchronousProcess {
}, Settings.getSessionTimeout * TICKS_PER_MINUTE);
plugin.sessions.put(name, task);
plugin.getSessions().put(name, task);
} else {
//plugin is disabled; we cannot schedule more tasks so run it directly here
postLogout(name);
@@ -117,6 +117,6 @@ public class AsynchronousQuit implements AsynchronousProcess {
private void postLogout(String name) {
PlayerCache.getInstance().removePlayer(name);
database.setUnlogged(name);
plugin.sessions.remove(name);
plugin.getSessions().remove(name);
}
}