From edaf14f2b6fd86f8dec99f67512a5c0095e391dc Mon Sep 17 00:00:00 2001 From: Unknwon Date: Wed, 5 Apr 2017 09:17:21 -0400 Subject: Refactoring: remove tool.TplName --- routers/repo/view.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'routers/repo/view.go') diff --git a/routers/repo/view.go b/routers/repo/view.go index 1559b984..0efa8ba2 100644 --- a/routers/repo/view.go +++ b/routers/repo/view.go @@ -18,19 +18,19 @@ import ( "github.com/gogits/git-module" "github.com/gogits/gogs/models" - "github.com/gogits/gogs/pkg/tool" "github.com/gogits/gogs/pkg/context" "github.com/gogits/gogs/pkg/markup" "github.com/gogits/gogs/pkg/setting" "github.com/gogits/gogs/pkg/template" "github.com/gogits/gogs/pkg/template/highlight" + "github.com/gogits/gogs/pkg/tool" ) const ( - BARE tool.TplName = "repo/bare" - HOME tool.TplName = "repo/home" - WATCHERS tool.TplName = "repo/watchers" - FORKS tool.TplName = "repo/forks" + BARE = "repo/bare" + HOME = "repo/home" + WATCHERS = "repo/watchers" + FORKS = "repo/forks" ) func renderDirectory(ctx *context.Context, treeLink string) { @@ -304,7 +304,7 @@ func Home(ctx *context.Context) { ctx.HTML(200, HOME) } -func RenderUserCards(ctx *context.Context, total int, getter func(page int) ([]*models.User, error), tpl tool.TplName) { +func RenderUserCards(ctx *context.Context, total int, getter func(page int) ([]*models.User, error), tpl string) { page := ctx.QueryInt("page") if page <= 0 { page = 1 -- cgit v1.2.3