mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-08 11:05:59 +08:00
ctx
This commit is contained in:
+2
-6
@@ -6,13 +6,9 @@ import (
|
||||
)
|
||||
|
||||
func GinError(c *gin.Context, err error) {
|
||||
if err == nil {
|
||||
GinSuccess(c, nil)
|
||||
return
|
||||
}
|
||||
c.JSON(http.StatusOK, apiError(err))
|
||||
c.JSON(http.StatusOK, ApiError(err))
|
||||
}
|
||||
|
||||
func GinSuccess(c *gin.Context, data any) {
|
||||
c.JSON(http.StatusOK, apiSuccess(data))
|
||||
c.JSON(http.StatusOK, ApiSuccess(data))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user