Skip to content

Commit

Permalink
fix #638
Browse files Browse the repository at this point in the history
  • Loading branch information
Akegarasu committed Feb 16, 2021
1 parent 32771eb commit 569a718
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions coolq/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,9 @@ func (bot *CQBot) formatGroupMessage(m *message.GroupMessage) MSG {
gm["sub_type"] = "anonymous"
} else {
mem := bot.Client.FindGroup(m.GroupCode).FindMember(m.Sender.Uin)
if mem == nil{
return Failed(100,"MEMBER_NOT_FOUND","群员不存在")
}
ms := gm["sender"].(MSG)
ms["role"] = func() string {
switch mem.Permission {
Expand Down

0 comments on commit 569a718

Please sign in to comment.