summaryrefslogtreecommitdiffstats
path: root/modules/context/repo.go
diff options
context:
space:
mode:
Diffstat (limited to 'modules/context/repo.go')
-rw-r--r--modules/context/repo.go6
1 files changed, 2 insertions, 4 deletions
diff --git a/modules/context/repo.go b/modules/context/repo.go
index f91dd6aa9a..a18dc873b6 100644
--- a/modules/context/repo.go
+++ b/modules/context/repo.go
@@ -668,11 +668,9 @@ func RepoAssignment(ctx *Context) context.CancelFunc {
branchOpts := git_model.FindBranchOptions{
RepoID: ctx.Repo.Repository.ID,
IsDeletedBranch: util.OptionalBoolFalse,
- ListOptions: db.ListOptions{
- ListAll: true,
- },
+ ListOptions: db.ListOptionsAll,
}
- branchesTotal, err := git_model.CountBranches(ctx, branchOpts)
+ branchesTotal, err := db.Count[git_model.Branch](ctx, branchOpts)
if err != nil {
ctx.ServerError("CountBranches", err)
return cancel