mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-22 01:34:18 +00:00
Strict pagination check (#32548)
(cherry picked from commit c363bd06e93986a564601527ade219d602c9d8dd)
Conflicts:
models/user/search.go
change already done in 9b85f97835
This commit is contained in:
parent
7bc6bd3095
commit
3135e146f9
8 changed files with 10 additions and 10 deletions
|
@ -163,7 +163,7 @@ func FindReactions(ctx context.Context, opts FindReactionsOptions) (ReactionList
|
|||
Where(opts.toConds()).
|
||||
In("reaction.`type`", setting.UI.Reactions).
|
||||
Asc("reaction.issue_id", "reaction.comment_id", "reaction.created_unix", "reaction.id")
|
||||
if opts.Page != 0 {
|
||||
if opts.Page > 0 {
|
||||
sess = db.SetSessionPagination(sess, &opts)
|
||||
|
||||
reactions := make([]*Reaction, 0, opts.PageSize)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue