From f9f59f1f96d262931de90466504372cd8fb54d03 Mon Sep 17 00:00:00 2001 From: extendedclip Date: Tue, 14 Jul 2020 10:24:01 -0400 Subject: [PATCH] Merge the multiple static blocks --- .../me/clip/placeholderapi/commands/CommandHandler.java | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/main/java/me/clip/placeholderapi/commands/CommandHandler.java b/src/main/java/me/clip/placeholderapi/commands/CommandHandler.java index dfdbcac..12374cd 100644 --- a/src/main/java/me/clip/placeholderapi/commands/CommandHandler.java +++ b/src/main/java/me/clip/placeholderapi/commands/CommandHandler.java @@ -51,15 +51,12 @@ public final class CommandHandler implements CommandExecutor { if (comparison == -1) return 1; return 0; }); + Objects.requireNonNull(PlaceholderAPIPlugin.getInstance().getCommand("placeholderapi")) + .setTabCompleter(new CompletionHandler(COMMANDS)); } private static final Pattern SPACE_PATTERN = Pattern.compile(" "); - static { - Objects.requireNonNull(PlaceholderAPIPlugin.getInstance().getCommand("placeholderapi")) - .setTabCompleter(new CompletionHandler(COMMANDS)); - } - @Override public boolean onCommand(@NotNull final CommandSender sender, @NotNull final org.bukkit.command.Command bukkitCommand, @NotNull final String name, @NotNull String[] args) {