summaryrefslogtreecommitdiffstats
path: root/modules/context/repo.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/context/repo.go')
-rw-r--r--modules/context/repo.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/modules/context/repo.go b/modules/context/repo.go
index 3e48b34b3d..72d1cf4c85 100644
--- a/modules/context/repo.go
+++ b/modules/context/repo.go
@@ -360,13 +360,17 @@ func repoAssignment(ctx *Context, repo *models.Repository) {
var err error
ctx.Repo.Mirror, err = models.GetMirrorByRepoID(repo.ID)
if err != nil {
- ctx.ServerError("GetMirror", err)
+ ctx.ServerError("GetMirrorByRepoID", err)
return
}
ctx.Data["MirrorEnablePrune"] = ctx.Repo.Mirror.EnablePrune
ctx.Data["MirrorInterval"] = ctx.Repo.Mirror.Interval
ctx.Data["Mirror"] = ctx.Repo.Mirror
}
+ if err = repo.LoadPushMirrors(); err != nil {
+ ctx.ServerError("LoadPushMirrors", err)
+ return
+ }
ctx.Repo.Repository = repo
ctx.Data["RepoName"] = ctx.Repo.Repository.Name