mirror of
https://github.com/darksaid98/Carbon.git
synced 2026-12-02 06:28:54 +00:00
Finalize class fields that can be final
This commit is contained in:
1 parent
15e105ac32
commit
a5da40fee5
18 files changed
+34
-43
No files matched your search
+2
-2
@@ -11,8 +11,8 @@ import org.bukkit.entity.Player;
|
||||
|
||||
public class AdventureManager {
|
||||
|
||||
private SimpleChat simpleChat;
|
||||
private BukkitAudiences audiences;
|
||||
private final SimpleChat simpleChat;
|
||||
private final BukkitAudiences audiences;
|
||||
|
||||
public AdventureManager(SimpleChat simpleChat) {
|
||||
this.simpleChat = simpleChat;
|
||||
|
||||
@@ -13,9 +13,9 @@ import java.util.Collections;
|
||||
|
||||
public class ChannelManager {
|
||||
|
||||
private ChannelRegistry registry;
|
||||
private final SimpleChat simpleChat;
|
||||
private final ChannelRegistry registry;
|
||||
private String defaultChannelKey = null;
|
||||
private SimpleChat simpleChat;
|
||||
|
||||
public ChannelManager(SimpleChat simpleChat) {
|
||||
this.simpleChat = simpleChat;
|
||||
|
||||
@@ -12,11 +12,9 @@ import java.util.List;
|
||||
|
||||
public class CommandManager {
|
||||
|
||||
private SimpleChat simpleChat;
|
||||
private BukkitCommandManager commandManager;
|
||||
private final BukkitCommandManager commandManager;
|
||||
|
||||
public CommandManager(SimpleChat simpleChat) {
|
||||
this.simpleChat = simpleChat;
|
||||
|
||||
commandManager = new BukkitCommandManager(simpleChat);
|
||||
|
||||
|
||||
+2
-2
@@ -18,8 +18,8 @@ import java.util.UUID;
|
||||
|
||||
public class PluginMessageManager implements PluginMessageListener {
|
||||
|
||||
private SimpleChat simpleChat;
|
||||
private BungeeChannelApi api;
|
||||
private final SimpleChat simpleChat;
|
||||
private final BungeeChannelApi api;
|
||||
|
||||
public PluginMessageManager(SimpleChat simpleChat) {
|
||||
this.simpleChat = simpleChat;
|
||||
|
||||
@@ -16,17 +16,14 @@ import java.util.UUID;
|
||||
|
||||
public class RedisManager {
|
||||
|
||||
private SimpleChat simpleChat;
|
||||
private final RedisClient client;
|
||||
private final StatefulRedisPubSubConnection<String, String> connection;
|
||||
private final RedisPubSubCommands<String, String> sync;
|
||||
|
||||
private RedisClient client;
|
||||
private StatefulRedisPubSubConnection<String, String> connection;
|
||||
private RedisPubSubCommands<String, String> sync;
|
||||
|
||||
private Gson gson = new GsonBuilder().setPrettyPrinting().create();
|
||||
private Type userType = new TypeToken<SimpleChatUser>() {}.getType();
|
||||
private final Gson gson = new GsonBuilder().setPrettyPrinting().create();
|
||||
private final Type userType = new TypeToken<SimpleChatUser>() {}.getType();
|
||||
|
||||
public RedisManager(SimpleChat simpleChat) {
|
||||
this.simpleChat = simpleChat;
|
||||
|
||||
String host = simpleChat.getConfig().getString("redis.host");
|
||||
int port = simpleChat.getConfig().getInt("redis.port");
|
||||
|
||||
Reference in new issue
Block a user