RefreshFriendCache 刷新好友缓存
()
| 177 | |
| 178 | // RefreshFriendCache 刷新好友缓存 |
| 179 | func (c *QQClient) RefreshFriendCache() error { |
| 180 | friends, err := c.GetFriendsData() |
| 181 | if err != nil { |
| 182 | return err |
| 183 | } |
| 184 | c.cache.RefreshAllFriend(friends) |
| 185 | unidirectionalFriends, err := c.GetUnidirectionalFriendList() |
| 186 | if err != nil { |
| 187 | return err |
| 188 | } |
| 189 | for _, f := range unidirectionalFriends { |
| 190 | c.cache.RefreshFriend(f) |
| 191 | } |
| 192 | return nil |
| 193 | } |
| 194 | |
| 195 | // RefreshGroupMemberCache 刷新一个群的指定群成员缓存 |
| 196 | func (c *QQClient) RefreshGroupMemberCache(groupUin, memberUin uint32) error { |
no test coverage detected