diff --git a/src/main/java/com/yutou/qqbot/utlis/ApplicationInit.java b/src/main/java/com/yutou/qqbot/utlis/ApplicationInit.java index 2e56aa6..797a3c2 100644 --- a/src/main/java/com/yutou/qqbot/utlis/ApplicationInit.java +++ b/src/main/java/com/yutou/qqbot/utlis/ApplicationInit.java @@ -33,6 +33,9 @@ public class ApplicationInit implements ApplicationRunner { new Thread(() -> { try { Bot bot = QQBotManager.getInstance().getBot(); + if(bot==null){ + return; + } Model useModel = (Model) model.getDeclaredConstructor().newInstance(); for (Group group : bot.getGroups()) { if (QQNumberManager.getManager().isUseModel(group.getId(), model)) {