From 2dcea782c5bae799b455694ba7149eae535457fc Mon Sep 17 00:00:00 2001 From: Tyrone Yeh Date: Thu, 8 Sep 2022 20:00:42 +0800 Subject: [PATCH] Fix pagination limit parameter problem (#21111) backport #21109 Co-authored-by: 6543 <6543@obermui.de> --- routers/web/repo/commit.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/routers/web/repo/commit.go b/routers/web/repo/commit.go index 164dc181f0..a6553256b0 100644 --- a/routers/web/repo/commit.go +++ b/routers/web/repo/commit.go @@ -83,7 +83,7 @@ func Commits(ctx *context.Context) { ctx.Data["CommitCount"] = commitsCount ctx.Data["RefName"] = ctx.Repo.RefName - pager := context.NewPagination(int(commitsCount), setting.Git.CommitsRangeSize, page, 5) + pager := context.NewPagination(int(commitsCount), pageSize, page, 5) pager.SetDefaultParams(ctx) ctx.Data["Page"] = pager