Cleanup, take 3

This commit is contained in:
Gabriele C
2016-08-09 14:53:22 +02:00
parent ec3db792ed
commit 4f1d6585cf
4 changed files with 73 additions and 53 deletions
@@ -1,6 +1,5 @@
package fr.xephi.authme.process.register;
import fr.xephi.authme.AuthMe;
import fr.xephi.authme.cache.auth.PlayerAuth;
import fr.xephi.authme.cache.auth.PlayerCache;
import fr.xephi.authme.datasource.DataSource;
@@ -8,6 +7,7 @@ import fr.xephi.authme.mail.SendMailSSL;
import fr.xephi.authme.output.MessageKey;
import fr.xephi.authme.permission.PermissionsManager;
import fr.xephi.authme.process.AsynchronousProcess;
import fr.xephi.authme.process.Management;
import fr.xephi.authme.process.ProcessService;
import fr.xephi.authme.process.SyncProcessManager;
import fr.xephi.authme.security.HashAlgorithm;
@@ -32,9 +32,6 @@ import static fr.xephi.authme.permission.PlayerStatePermission.ALLOW_MULTIPLE_AC
public class AsyncRegister implements AsynchronousProcess {
@Inject
private AuthMe plugin;
@Inject
private DataSource database;
@@ -59,6 +56,9 @@ public class AsyncRegister implements AsynchronousProcess {
@Inject
private SendMailSSL sendMailSsl;
@Inject
private Management management;
AsyncRegister() { }
private boolean preRegisterCheck(Player player, String password) {
@@ -163,7 +163,7 @@ public class AsyncRegister implements AsynchronousProcess {
}
if (!service.getProperty(RegistrationSettings.FORCE_LOGIN_AFTER_REGISTER) && autoLogin) {
plugin.getManagement().performLogin(player, "dontneed", true);
management.performLogin(player, "dontneed", true);
}
syncProcessManager.processSyncPasswordRegister(player);