aboutsummaryrefslogtreecommitdiffstats
path: root/routers/repo/view.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/repo/view.go')
-rw-r--r--routers/repo/view.go11
1 files changed, 6 insertions, 5 deletions
diff --git a/routers/repo/view.go b/routers/repo/view.go
index 39f16d183c..568d9ec6be 100644
--- a/routers/repo/view.go
+++ b/routers/repo/view.go
@@ -12,6 +12,7 @@ import (
gotemplate "html/template"
"io"
"io/ioutil"
+ "net/http"
"net/url"
"path"
"strconv"
@@ -582,7 +583,7 @@ func Home(ctx *context.Context) {
ctx.Data["Repo"] = ctx.Repo
ctx.Data["MigrateTask"] = task
ctx.Data["CloneAddr"] = safeURL(cfg.CloneAddr)
- ctx.HTML(200, tplMigrating)
+ ctx.HTML(http.StatusOK, tplMigrating)
return
}
@@ -641,7 +642,7 @@ func renderCode(ctx *context.Context) {
ctx.Data["PageIsViewCode"] = true
if ctx.Repo.Repository.IsEmpty {
- ctx.HTML(200, tplRepoEMPTY)
+ ctx.HTML(http.StatusOK, tplRepoEMPTY)
return
}
@@ -704,7 +705,7 @@ func renderCode(ctx *context.Context) {
ctx.Data["TreeLink"] = treeLink
ctx.Data["TreeNames"] = treeNames
ctx.Data["BranchLink"] = branchLink
- ctx.HTML(200, tplRepoHome)
+ ctx.HTML(http.StatusOK, tplRepoHome)
}
// RenderUserCards render a page show users according the input templaet
@@ -726,7 +727,7 @@ func RenderUserCards(ctx *context.Context, total int, getter func(opts models.Li
}
ctx.Data["Cards"] = items
- ctx.HTML(200, tpl)
+ ctx.HTML(http.StatusOK, tpl)
}
// Watchers render repository's watch users
@@ -765,5 +766,5 @@ func Forks(ctx *context.Context) {
}
ctx.Data["Forks"] = forks
- ctx.HTML(200, tplForks)
+ ctx.HTML(http.StatusOK, tplForks)
}