diff options
author | wxiaoguang <wxiaoguang@gmail.com> | 2023-07-07 23:27:12 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-07-07 17:27:12 +0200 |
commit | 128d77a3a05c3bde86d5e1f2ac299dbd9c434e2d (patch) | |
tree | 563f7826ae0fc541b990000112932bd9f8733afe /routers | |
parent | a6a9389c702abcb003cbd4a304ec3650345fc14f (diff) | |
download | gitea-128d77a3a05c3bde86d5e1f2ac299dbd9c434e2d.tar.gz gitea-128d77a3a05c3bde86d5e1f2ac299dbd9c434e2d.zip |
Following up fixes for "Fix inconsistent user profile layout across tabs" (#25739)
Follow
https://github.com/go-gitea/gitea/pull/25625#issuecomment-1621577816
1. Fix the incorrect "project view" layout
2. Fix the "follow/unfollow" link on "packages" and "projects" tab
Before:

After:

---------
Co-authored-by: Giteabot <teabot@gitea.io>
Diffstat (limited to 'routers')
-rw-r--r-- | routers/web/user/profile.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/routers/web/user/profile.go b/routers/web/user/profile.go index 442fd0433a..07a2261c96 100644 --- a/routers/web/user/profile.go +++ b/routers/web/user/profile.go @@ -287,9 +287,9 @@ func Action(ctx *context.Context) { } if err != nil { - ctx.ServerError(fmt.Sprintf("Action (%s)", ctx.FormString("action")), err) + log.Error("Failed to apply action %q: %v", ctx.FormString("action"), err) + ctx.JSONError(fmt.Sprintf("Action %q failed", ctx.FormString("action"))) return } - // FIXME: We should check this URL and make sure that it's a valid Gitea URL - ctx.RedirectToFirst(ctx.FormString("redirect_to"), ctx.ContextUser.HomeLink()) + ctx.JSONOK() } |