mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-20 08:49:01 +08:00
OA tag fields modify
This commit is contained in:
@@ -491,7 +491,7 @@ func (d *DataBases) SetTag(userID, tagID, newName string, increaseUserIDList []s
|
||||
}
|
||||
}
|
||||
tag.UserList = append(tag.UserList, increaseUserIDList...)
|
||||
tag.UserList = utils.RemoveUserIDRepByMap(tag.UserList)
|
||||
tag.UserList = utils.RemoveRepeatedStringInList(tag.UserList)
|
||||
for _, v := range reduceUserIDList {
|
||||
for i2, v2 := range tag.UserList {
|
||||
if v == v2 {
|
||||
|
||||
+1
-1
@@ -77,7 +77,7 @@ func OperationIDGenerator() string {
|
||||
return strconv.FormatInt(time.Now().UnixNano()+int64(rand.Uint32()), 10)
|
||||
}
|
||||
|
||||
func RemoveUserIDRepByMap(slc []string) []string {
|
||||
func RemoveRepeatedStringInList(slc []string) []string {
|
||||
var result []string
|
||||
tempMap := map[string]byte{}
|
||||
for _, e := range slc {
|
||||
|
||||
Reference in New Issue
Block a user