#432 Injector improvements
- Separate FieldInjection from default fallback for no-Inject public no-args constructor classes - Make CommandInitializer a normal, instantiable service - Add various injections instead of fetching through command service
This commit is contained in:
@@ -2,8 +2,10 @@ package fr.xephi.authme.command.executable.logout;
|
||||
|
||||
import fr.xephi.authme.command.CommandService;
|
||||
import fr.xephi.authme.command.PlayerCommand;
|
||||
import fr.xephi.authme.process.Management;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import javax.inject.Inject;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -11,8 +13,11 @@ import java.util.List;
|
||||
*/
|
||||
public class LogoutCommand extends PlayerCommand {
|
||||
|
||||
@Inject
|
||||
private Management management;
|
||||
|
||||
@Override
|
||||
public void runCommand(Player player, List<String> arguments, CommandService commandService) {
|
||||
commandService.getManagement().performLogout(player);
|
||||
management.performLogout(player);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user