mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-01-10 01:25:33 +00:00
Remove unnecessary code (#32560)
PushMirrors only be used in the repository setting page. So it should not be loaded on every repository page. (cherry picked from commit 0d5abd9b3e04a09f5d7de720c99e3451723e028e)
This commit is contained in:
parent
203f79a121
commit
f3afd18b76
|
@ -413,14 +413,7 @@ func repoAssignment(ctx *Context, repo *repo_model.Repository) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pushMirrors, _, err := repo_model.GetPushMirrorsByRepoID(ctx, repo.ID, db.ListOptions{})
|
|
||||||
if err != nil {
|
|
||||||
ctx.ServerError("GetPushMirrorsByRepoID", err)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
ctx.Repo.Repository = repo
|
ctx.Repo.Repository = repo
|
||||||
ctx.Data["PushMirrors"] = pushMirrors
|
|
||||||
ctx.Data["RepoName"] = ctx.Repo.Repository.Name
|
ctx.Data["RepoName"] = ctx.Repo.Repository.Name
|
||||||
ctx.Data["IsEmptyRepo"] = ctx.Repo.Repository.IsEmpty
|
ctx.Data["IsEmptyRepo"] = ctx.Repo.Repository.IsEmpty
|
||||||
ctx.Data["DefaultWikiBranchName"] = setting.Repository.DefaultBranch
|
ctx.Data["DefaultWikiBranchName"] = setting.Repository.DefaultBranch
|
||||||
|
|
Loading…
Reference in a new issue