diff options
author | mdxd44 <ogurec332@mail.ru> | 2021-12-31 04:09:11 +0900 |
---|---|---|
committer | mdxd44 <ogurec332@mail.ru> | 2021-12-31 04:09:11 +0900 |
commit | 3741fffd23660ac8c913a18ecf2075e3d71a7b55 (patch) | |
tree | 4dc1751c00ff09bc42e739d367d8f0a7366f05e9 /src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java | |
parent | da4612bb4fb9ba00fb2b518984ce61ff8468b7b9 (diff) | |
download | LimboAuth-3741fffd23660ac8c913a18ecf2075e3d71a7b55.tar.gz LimboAuth-3741fffd23660ac8c913a18ecf2075e3d71a7b55.tar.bz2 LimboAuth-3741fffd23660ac8c913a18ecf2075e3d71a7b55.zip |
Add floodgate support, release candidate 2.
Diffstat (limited to 'src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java')
-rw-r--r-- | src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java b/src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java index 611b1c3..1465023 100644 --- a/src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java +++ b/src/main/java/net/elytrium/limboauth/command/LimboAuthCommand.java @@ -30,6 +30,12 @@ import net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer; public class LimboAuthCommand implements SimpleCommand { + private final LimboAuth plugin; + + public LimboAuthCommand(LimboAuth plugin) { + this.plugin = plugin; + } + @Override public List<String> suggest(SimpleCommand.Invocation invocation) { CommandSource source = invocation.source(); @@ -57,7 +63,7 @@ public class LimboAuthCommand implements SimpleCommand { if (args.length == 1) { if (args[0].equalsIgnoreCase("reload") && source.hasPermission("limboauth.admin.reload")) { try { - LimboAuth.getInstance().reload(); + this.plugin.reload(); source.sendMessage(LegacyComponentSerializer.legacyAmpersand().deserialize(Settings.IMP.MAIN.STRINGS.RELOAD)); } catch (Exception e) { source.sendMessage(LegacyComponentSerializer.legacyAmpersand().deserialize(Settings.IMP.MAIN.STRINGS.RELOAD_FAILED)); |