aboutsummaryrefslogtreecommitdiff
path: root/modules/context/repo.go
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2017-03-10 15:13:48 -0500
committerUnknwon <u@gogs.io>2017-03-10 15:13:48 -0500
commitebc0943713196abe939e445f35e0f726f5cbee1e (patch)
treee4f7248ba87586c12129bd36718f27d571ece513 /modules/context/repo.go
parent451aef7a1c177b58c4519239a65dbfbab32b4888 (diff)
templates/repo: only show Git stats in repository home page (#3518)
Move 'Commits' and 'Releases' tabs down to body. This patch also reduces page load time for pages that do not need to use commits count anywhere. Get commits count can hurt performance badly for huge repositories that has tens of thousands commits like Linux Kernel.
Diffstat (limited to 'modules/context/repo.go')
-rw-r--r--modules/context/repo.go7
1 files changed, 0 insertions, 7 deletions
diff --git a/modules/context/repo.go b/modules/context/repo.go
index 398b32c0..6a2911a7 100644
--- a/modules/context/repo.go
+++ b/modules/context/repo.go
@@ -456,13 +456,6 @@ func RepoRef() macaron.Handler {
}
}
ctx.Data["PullRequestCtx"] = ctx.Repo.PullRequest
-
- ctx.Repo.CommitsCount, err = ctx.Repo.Commit.CommitsCount()
- if err != nil {
- ctx.Handle(500, "CommitsCount", err)
- return
- }
- ctx.Data["CommitsCount"] = ctx.Repo.CommitsCount
}
}