aboutsummaryrefslogtreecommitdiffstats
path: root/services/context/repo.go
diff options
context:
space:
mode:
Diffstat (limited to 'services/context/repo.go')
-rw-r--r--services/context/repo.go9
1 files changed, 1 insertions, 8 deletions
diff --git a/services/context/repo.go b/services/context/repo.go
index 1eafb7ca48..cf328ca97b 100644
--- a/services/context/repo.go
+++ b/services/context/repo.go
@@ -396,13 +396,6 @@ func repoAssignment(ctx *Context, repo *repo_model.Repository) {
ctx.Repo.Repository = repo
ctx.Data["RepoName"] = ctx.Repo.Repository.Name
ctx.Data["IsEmptyRepo"] = ctx.Repo.Repository.IsEmpty
-
- repoLicenses, err := repo_model.GetRepoLicenses(ctx, ctx.Repo.Repository)
- if err != nil {
- ctx.ServerError("GetRepoLicenses", err)
- return
- }
- ctx.Data["DetectedRepoLicenses"] = repoLicenses.StringList()
}
// RepoAssignment returns a middleware to handle repository assignment
@@ -1036,7 +1029,7 @@ func RepoRefByType(detectRefType RepoRefType, opts ...RepoRefByTypeOptions) func
ctx.Data["IsViewBranch"] = ctx.Repo.IsViewBranch
ctx.Data["IsViewTag"] = ctx.Repo.IsViewTag
ctx.Data["IsViewCommit"] = ctx.Repo.IsViewCommit
- ctx.Data["CanCreateBranch"] = ctx.Repo.CanCreateBranch()
+ ctx.Data["CanCreateBranch"] = ctx.Repo.CanCreateBranch() // only used by the branch selector dropdown: AllowCreateNewRef
ctx.Repo.CommitsCount, err = ctx.Repo.GetCommitsCount()
if err != nil {