lets only inject in one place (moved injects to constructor)

This commit is contained in:
Gnat008 2016-06-12 14:53:18 -04:00
parent ac4add9f54
commit c3d391aeaf

View File

@ -11,6 +11,7 @@ import org.bukkit.BanList;
import org.bukkit.Bukkit; import org.bukkit.Bukkit;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import javax.annotation.PostConstruct;
import javax.inject.Inject; import javax.inject.Inject;
import java.util.Date; import java.util.Date;
import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentHashMap;
@ -24,10 +25,8 @@ public class TempbanManager implements SettingsDependent {
private final long MINUTE_IN_MILLISECONDS = 60000; private final long MINUTE_IN_MILLISECONDS = 60000;
@Inject
private BukkitService bukkitService; private BukkitService bukkitService;
@Inject
private Messages messages; private Messages messages;
private boolean isEnabled; private boolean isEnabled;
@ -36,7 +35,7 @@ public class TempbanManager implements SettingsDependent {
@Inject @Inject
TempbanManager(NewSetting settings) { TempbanManager(NewSetting settings) {
this.playerCounts = new ConcurrentHashMap<>(); playerCounts = new ConcurrentHashMap<>();
loadSettings(settings); loadSettings(settings);
} }