fix: 优化日志

This commit is contained in:
ikechan8370 2023-03-05 17:01:27 +08:00
parent 62b64ed92f
commit 2c5d573ec2

View file

@ -47,6 +47,7 @@ export class Entertainment extends plugin {
} }
async sendRandomMessage () { async sendRandomMessage () {
logger.info('开始处理ChatGPT随机打招呼。')
let toSend = Config.initiativeChatGroups || [] let toSend = Config.initiativeChatGroups || []
for (let i = 0; i < toSend.length; i++) { for (let i = 0; i < toSend.length; i++) {
let groupId = parseInt(toSend[i]) let groupId = parseInt(toSend[i])
@ -60,6 +61,8 @@ export class Entertainment extends plugin {
} else { } else {
await Bot.sendGroupMsg(groupId, message) await Bot.sendGroupMsg(groupId, message)
} }
} else {
logger.info(`这次就不打招呼给群聊${groupId}`)
} }
} else { } else {
logger.warn('机器人不在要发送的群组里,忽略群' + groupId) logger.warn('机器人不在要发送的群组里,忽略群' + groupId)