merge the latest main

This commit is contained in:
withchao
2024-03-07 18:00:58 +08:00
parent 76d8253aeb
commit d4ed448d7d
25 changed files with 764 additions and 644 deletions
-12
View File
@@ -16,7 +16,6 @@ package push
import (
"context"
"encoding/json"
"github.com/OpenIMSDK/protocol/constant"
"github.com/OpenIMSDK/protocol/sdkws"
@@ -136,14 +135,3 @@ func callbackBeforeSuperGroupOnlinePush(
}
return nil
}
func GetContent(msg *sdkws.MsgData) string {
if msg.ContentType >= constant.NotificationBegin && msg.ContentType <= constant.NotificationEnd {
var notification sdkws.NotificationElem
if err := json.Unmarshal(msg.Content, &notification); err != nil {
return ""
}
return notification.Detail
} else {
return string(msg.Content)
}
}