修复定时器获取bot为空导致异常问题
This commit is contained in:
@@ -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)) {
|
||||
|
||||
Reference in New Issue
Block a user