Skip to content

Commit 333450c

Browse files
update command: load needed class before updating
1 parent a946896 commit 333450c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/main/java/org/maxgamer/quickshop/command/subcommand/SubCommand_Update.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
import org.maxgamer.quickshop.QuickShop;
2828
import org.maxgamer.quickshop.api.command.CommandHandler;
2929
import org.maxgamer.quickshop.util.MsgUtil;
30+
import org.maxgamer.quickshop.util.Util;
3031
import org.maxgamer.quickshop.util.updater.QuickUpdater;
3132

3233
import java.util.logging.Level;
@@ -56,6 +57,8 @@ public void onCommand(@NotNull CommandSender sender, @NotNull String commandLabe
5657
MsgUtil.sendDirectMessage(sender, ChatColor.RED + "Type " + ChatColor.BOLD + "/qs update confirm" + ChatColor.RESET + ChatColor.RED + " to confirm update");
5758
return;
5859
}
60+
//Let JVM load this class
61+
Util.isClassAvailable("org.maxgamer.quickshop.BootError");
5962
MsgUtil.sendDirectMessage(sender, ChatColor.YELLOW + "Downloading update! This may take a while...");
6063
try {
6164
updater.installUpdate();

0 commit comments

Comments
 (0)