diff options
author | Unknwon <u@gogs.io> | 2016-07-24 00:23:54 +0800 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2016-07-24 00:23:54 +0800 |
commit | 46e96c008cf966428c9dad71c7871de88186e3fe (patch) | |
tree | 57e276d8f971c74a6dac841352ec2bee96e93d8f /routers/repo | |
parent | 256cd6374adf646a46265efe18a2d3f822bf7269 (diff) | |
download | gitea-46e96c008cf966428c9dad71c7871de88186e3fe.tar.gz gitea-46e96c008cf966428c9dad71c7871de88186e3fe.zip |
Use struct for UI settings
Diffstat (limited to 'routers/repo')
-rw-r--r-- | routers/repo/issue.go | 4 | ||||
-rw-r--r-- | routers/repo/view.go | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/routers/repo/issue.go b/routers/repo/issue.go index 52524297da..1562845bad 100644 --- a/routers/repo/issue.go +++ b/routers/repo/issue.go @@ -163,7 +163,7 @@ func Issues(ctx *context.Context) { } else { total = int(issueStats.ClosedCount) } - pager := paginater.New(total, setting.IssuePagingNum, page, 5) + pager := paginater.New(total, setting.UI.IssuePagingNum, page, 5) ctx.Data["Page"] = pager // Get issues. @@ -1017,7 +1017,7 @@ func Milestones(ctx *context.Context) { } else { total = int(closedCount) } - ctx.Data["Page"] = paginater.New(total, setting.IssuePagingNum, page, 5) + ctx.Data["Page"] = paginater.New(total, setting.UI.IssuePagingNum, page, 5) miles, err := models.GetMilestones(ctx.Repo.Repository.ID, page, isShowClosed) if err != nil { diff --git a/routers/repo/view.go b/routers/repo/view.go index e787879d86..7bcdc1293c 100644 --- a/routers/repo/view.go +++ b/routers/repo/view.go @@ -105,7 +105,7 @@ func Home(ctx *context.Context) { case isImageFile: ctx.Data["IsImageFile"] = true case isTextFile: - if blob.Size() >= setting.MaxDisplayFileSize { + if blob.Size() >= setting.UI.MaxDisplayFileSize { ctx.Data["IsFileTooLarge"] = true } else { ctx.Data["IsFileTooLarge"] = false |