From e0aacc7624238caaf959c512362ec2b69565c444 Mon Sep 17 00:00:00 2001 From: puni9869 <80308335+puni9869@users.noreply.github.com> Date: Wed, 13 Sep 2023 16:17:35 +0530 Subject: [PATCH] Show the repo count in code tab on both user profile and org page. (#27048) as title Screenshot before User Profile page image after image Org page image --------- Co-authored-by: wxiaoguang --- routers/web/user/code.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/routers/web/user/code.go b/routers/web/user/code.go index 29b8b91c89..42d7284189 100644 --- a/routers/web/user/code.go +++ b/routers/web/user/code.go @@ -27,6 +27,11 @@ func CodeSearch(ctx *context.Context) { shared_user.PrepareContextForProfileBigAvatar(ctx) shared_user.RenderUserHeader(ctx) + if err := shared_user.LoadHeaderCount(ctx); err != nil { + ctx.ServerError("LoadHeaderCount", err) + return + } + ctx.Data["IsPackageEnabled"] = setting.Packages.Enabled ctx.Data["IsRepoIndexerEnabled"] = setting.Indexer.RepoIndexerEnabled ctx.Data["Title"] = ctx.Tr("explore.code")