mirror of
https://github.com/go-gitea/gitea
synced 2025-07-23 02:38:35 +00:00
Show always repo count in header (#26842)
A few pages don't load the repo count of an user/org, so it is not shown in the header. This happens mostly on org pages, but the package settings applies to the user page as well. Before:  After:  Seen on #26826 Regression of #25928
This commit is contained in:
@@ -25,6 +25,7 @@ import (
|
||||
"code.gitea.io/gitea/modules/setting"
|
||||
"code.gitea.io/gitea/modules/web"
|
||||
"code.gitea.io/gitea/routers/utils"
|
||||
shared_user "code.gitea.io/gitea/routers/web/shared/user"
|
||||
"code.gitea.io/gitea/services/convert"
|
||||
"code.gitea.io/gitea/services/forms"
|
||||
org_service "code.gitea.io/gitea/services/org"
|
||||
@@ -57,6 +58,12 @@ func Teams(ctx *context.Context) {
|
||||
}
|
||||
ctx.Data["Teams"] = ctx.Org.Teams
|
||||
|
||||
err := shared_user.LoadHeaderCount(ctx)
|
||||
if err != nil {
|
||||
ctx.ServerError("LoadHeaderCount", err)
|
||||
return
|
||||
}
|
||||
|
||||
ctx.HTML(http.StatusOK, tplTeams)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user