🎨优化代码

This commit is contained in:
comma 2024-01-06 16:37:02 +08:00
parent 919f53913a
commit 418e4e7980

View File

@ -141,7 +141,7 @@ func (w *WxHelper) GetContactList(isShowTool bool) (friends []Friend, err error)
var onlyFriends []Friend var onlyFriends []Friend
for _, v := range friends { for _, v := range friends {
// 固定开头 // 固定开头
if strings.HasPrefix(v.Wxid, "wxid") { if strings.HasPrefix(v.Wxid, "wxid") || strings.HasSuffix(v.Wxid, "@chatroom") {
onlyFriends = append(onlyFriends, v) onlyFriends = append(onlyFriends, v)
} }
} }