mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-02 16:15:59 +08:00
ws and push update
This commit is contained in:
@@ -51,7 +51,14 @@ func IsContainInt32(target int32, List []int32) bool {
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func IsContainInt(target int, List []int) bool {
|
||||
for _, element := range List {
|
||||
if target == element {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
func InterfaceArrayToStringArray(data []interface{}) (i []string) {
|
||||
for _, param := range data {
|
||||
i = append(i, param.(string))
|
||||
|
||||
+1
-1
@@ -149,7 +149,7 @@ func String2Pb(s string, pb proto.Message) error {
|
||||
return proto.Unmarshal([]byte(s), pb)
|
||||
}
|
||||
|
||||
func Map2Pb(m map[string]interface{}) (pb proto.Message, err error) {
|
||||
func Map2Pb(m map[string]string) (pb proto.Message, err error) {
|
||||
b, err := json.Marshal(m)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
Reference in New Issue
Block a user