diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2021-07-29 09:42:15 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-29 03:42:15 +0200 |
commit | 33e0b38287fdc3487112062300b8dd3c95415ee7 (patch) | |
tree | 603394d8f303de1031c21da0d3d3a3cdc0b2bfda /modules/context/api.go | |
parent | 370516883717de0e6e2087c12d368eb1465ee3b0 (diff) | |
download | gitea-33e0b38287fdc3487112062300b8dd3c95415ee7.tar.gz gitea-33e0b38287fdc3487112062300b8dd3c95415ee7.zip |
Rename context.Query to context.Form (#16562)
Diffstat (limited to 'modules/context/api.go')
-rw-r--r-- | modules/context/api.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/context/api.go b/modules/context/api.go index 78d48e9169..a21e0d7402 100644 --- a/modules/context/api.go +++ b/modules/context/api.go @@ -177,7 +177,7 @@ func genAPILinks(curURL *url.URL, total, pageSize, curPage int) []string { // SetLinkHeader sets pagination link header by given total number and page size. func (ctx *APIContext) SetLinkHeader(total, pageSize int) { - links := genAPILinks(ctx.Req.URL, total, pageSize, ctx.QueryInt("page")) + links := genAPILinks(ctx.Req.URL, total, pageSize, ctx.FormInt("page")) if len(links) > 0 { ctx.Header().Set("Link", strings.Join(links, ",")) |