|
|
|
@@ -608,6 +608,11 @@ func getContributorInfo(contributorInfos []*ContributorInfo, email string) *Cont |
|
|
|
|
|
|
|
// Home render repository home page |
|
|
|
func Home(ctx *context.Context) { |
|
|
|
if ctx.Repo.CanEnableEditor() { |
|
|
|
ctx.Data["CanEditFile"] = true |
|
|
|
} else { |
|
|
|
ctx.Data["CanEditFile"] = false |
|
|
|
} |
|
|
|
if len(ctx.Repo.Units) > 0 { |
|
|
|
//get repo contributors info |
|
|
|
contributors, err := git.GetContributors(ctx.Repo.Repository.RepoPath(), ctx.Repo.BranchName) |
|
|
|
|