1
0
mirror of https://github.com/Mrs4s/go-cqhttp.git synced 2025-05-07 12:43:31 +08:00

Merge branch 'master' into dev

This commit is contained in:
Mrs4s 2021-04-11 17:57:33 +08:00
commit 056f10ff64
No known key found for this signature in database
GPG Key ID: 3186E98FA19CE3A7

View File

@ -316,7 +316,10 @@ func (bot *CQBot) SendPrivateMessage(target int64, groupID int64, m *message.Sen
log.Errorf("错误: 群员(%v) 不在 群(%v), 无法发起临时会话", target, groupID)
default:
if session == nil && groupID != 0 {
bot.Client.SendGroupTempMessage(groupID, target, m)
msg := bot.Client.SendGroupTempMessage(groupID, target, m)
if msg != nil {
id = bot.InsertTempMessage(target, msg)
}
break
}
msg, err := session.(*client.TempSessionInfo).SendMessage(m)