aboutsummaryrefslogtreecommitdiff
path: root/routers/repo/repo.go
diff options
context:
space:
mode:
authorUnknwon <u@gogs.io>2017-04-05 09:17:21 -0400
committerUnknwon <u@gogs.io>2017-04-05 09:17:21 -0400
commitedaf14f2b6fd86f8dec99f67512a5c0095e391dc (patch)
treeec81011348a0c8df3995c36b46e2646472106800 /routers/repo/repo.go
parent6fbb984ebf4f0d6804f0f83e6edb12ef0bb9a570 (diff)
Refactoring: remove tool.TplName
Diffstat (limited to 'routers/repo/repo.go')
-rw-r--r--routers/repo/repo.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/routers/repo/repo.go b/routers/repo/repo.go
index 2e00a80e..2781da9a 100644
--- a/routers/repo/repo.go
+++ b/routers/repo/repo.go
@@ -17,15 +17,15 @@ import (
"github.com/gogits/gogs/models"
"github.com/gogits/gogs/models/errors"
- "github.com/gogits/gogs/pkg/tool"
"github.com/gogits/gogs/pkg/context"
"github.com/gogits/gogs/pkg/form"
"github.com/gogits/gogs/pkg/setting"
+ "github.com/gogits/gogs/pkg/tool"
)
const (
- CREATE tool.TplName = "repo/create"
- MIGRATE tool.TplName = "repo/migrate"
+ CREATE = "repo/create"
+ MIGRATE = "repo/migrate"
)
func MustBeNotBare(ctx *context.Context) {
@@ -85,7 +85,7 @@ func Create(ctx *context.Context) {
ctx.HTML(200, CREATE)
}
-func handleCreateError(ctx *context.Context, owner *models.User, err error, name string, tpl tool.TplName, form interface{}) {
+func handleCreateError(ctx *context.Context, owner *models.User, err error, name, tpl string, form interface{}) {
switch {
case models.IsErrReachLimitOfRepo(err):
ctx.RenderWithErr(ctx.Tr("repo.form.reach_limit_of_creation", owner.RepoCreationNum()), tpl, form)