mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-14 22:15:59 +08:00
feat: merge v3dev into main
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
package apiresp
|
||||
|
||||
type ApiFormat interface {
|
||||
ApiFormat()
|
||||
}
|
||||
@@ -49,6 +49,9 @@ func isAllFieldsPrivate(v any) bool {
|
||||
}
|
||||
|
||||
func ApiSuccess(data any) *ApiResponse {
|
||||
if format, ok := data.(ApiFormat); ok {
|
||||
format.ApiFormat()
|
||||
}
|
||||
if isAllFieldsPrivate(data) {
|
||||
return &ApiResponse{}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user