diff options
author | silverwind <me@silverwind.io> | 2023-07-05 05:41:32 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-04 23:41:32 -0400 |
commit | 24e64fe37225a315c74c00d1f5e4d024168feea6 (patch) | |
tree | c89664dca5a884d5fc0a322815ce3bc20247cf84 /routers/api/v1/user | |
parent | 4e310133f95ba8581c121a32596807721bdd6af9 (diff) | |
download | gitea-24e64fe37225a315c74c00d1f5e4d024168feea6.tar.gz gitea-24e64fe37225a315c74c00d1f5e4d024168feea6.zip |
Replace `interface{}` with `any` (#25686) (#25687)
Same perl replacement as https://github.com/go-gitea/gitea/pull/25686
but for 1.20 to ease future backporting.
Diffstat (limited to 'routers/api/v1/user')
-rw-r--r-- | routers/api/v1/user/user.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/routers/api/v1/user/user.go b/routers/api/v1/user/user.go index 314116962b..2a2361be67 100644 --- a/routers/api/v1/user/user.go +++ b/routers/api/v1/user/user.go @@ -62,7 +62,7 @@ func Search(ctx *context.APIContext) { ListOptions: listOptions, }) if err != nil { - ctx.JSON(http.StatusInternalServerError, map[string]interface{}{ + ctx.JSON(http.StatusInternalServerError, map[string]any{ "ok": false, "error": err.Error(), }) @@ -72,7 +72,7 @@ func Search(ctx *context.APIContext) { ctx.SetLinkHeader(int(maxResults), listOptions.PageSize) ctx.SetTotalCountHeader(maxResults) - ctx.JSON(http.StatusOK, map[string]interface{}{ + ctx.JSON(http.StatusOK, map[string]any{ "ok": true, "data": convert.ToUsers(ctx, ctx.Doer, users), }) |