diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-08-23 17:36:57 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-23 17:36:57 +0800 |
commit | e8b990999f89535269d20983079a40a0a9488eff (patch) | |
tree | 3a16640046072a51a9020e917457a801461860c2 /routers/web/admin/users.go | |
parent | af33a1187b0ed7cf1ffbe8aabddf7ed0380f2cc9 (diff) | |
download | gitea-e8b990999f89535269d20983079a40a0a9488eff.tar.gz gitea-e8b990999f89535269d20983079a40a0a9488eff.zip |
Make "link-action" backend code respond correct JSON content (#26680)
Otherwise the `link-action` JS code couldn't parse the response.
Co-authored-by: Giteabot <teabot@gitea.io>
Diffstat (limited to 'routers/web/admin/users.go')
-rw-r--r-- | routers/web/admin/users.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/web/admin/users.go b/routers/web/admin/users.go index 03c89bdab1..e560a88b4c 100644 --- a/routers/web/admin/users.go +++ b/routers/web/admin/users.go @@ -480,5 +480,5 @@ func DeleteAvatar(ctx *context.Context) { ctx.Flash.Error(err.Error()) } - ctx.Redirect(setting.AppSubURL + "/admin/users/" + strconv.FormatInt(u.ID, 10)) + ctx.JSONRedirect(setting.AppSubURL + "/admin/users/" + strconv.FormatInt(u.ID, 10)) } |