feat: 在 actionManager 中添加等待机制,确保在发送消息前 bot 已启动;新增初始化处理程序以发送初始化完成消息
This commit is contained in:
18
handler/init/init.go
Normal file
18
handler/init/init.go
Normal file
@@ -0,0 +1,18 @@
|
||||
package init
|
||||
|
||||
import (
|
||||
"git.lxtend.com/qqbot/action"
|
||||
"git.lxtend.com/qqbot/config"
|
||||
"git.lxtend.com/qqbot/model"
|
||||
)
|
||||
|
||||
func init() {
|
||||
action.ActionManager.SendMsg(model.Reply{
|
||||
ReplyMsg: "初始化完成",
|
||||
FromMsg: model.Message{
|
||||
GroupInfo: model.GroupInfo{
|
||||
GroupId: config.ConfigManager.GetConfig().Management.ReportGroup,
|
||||
},
|
||||
},
|
||||
})
|
||||
}
|
||||
Reference in New Issue
Block a user