更改十分钟内注册逻辑

This commit is contained in:
Sabrita
2023-02-28 13:22:15 +08:00
parent e109094472
commit bdf7816306
2 changed files with 3 additions and 5 deletions
@@ -180,17 +180,15 @@ public class RegisterCommand extends PlayerCommand {
@Override
public void run() {
if (dataSource.getAuth(player.getName()) != null) {
if (dataSource.getAuth(player.getName()).getLastLogin() == null && (dataSource.getAuth(player.getName()).getRegistrationDate() + 600000) < System.currentTimeMillis()) {
if (dataSource.getAuth(player.getName()).getLastLogin() == null) {
management.performUnregisterByAdmin(null, player.getName(), player);
timer.cancel();
} else if (dataSource.getAuth(player.getName()).getLastLogin() != null) {
timer.cancel();
}
} else {
timer.cancel();
}
}
}, 60000, 60000);
}, 600000);
}
}