Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/finders/branches_finder.rb')
-rw-r--r--app/finders/branches_finder.rb8
1 files changed, 3 insertions, 5 deletions
diff --git a/app/finders/branches_finder.rb b/app/finders/branches_finder.rb
index dc7b9f6a0ce..8f90ce40bb4 100644
--- a/app/finders/branches_finder.rb
+++ b/app/finders/branches_finder.rb
@@ -1,13 +1,11 @@
# frozen_string_literal: true
class BranchesFinder < GitRefsFinder
- def initialize(repository, params = {})
- super(repository, params)
- end
-
def execute(gitaly_pagination: false)
if gitaly_pagination && names.blank? && search.blank? && regex.blank?
- repository.branches_sorted_by(sort, pagination_params)
+ repository.branches_sorted_by(sort, pagination_params).tap do |branches|
+ set_next_cursor(branches)
+ end
else
branches = repository.branches_sorted_by(sort)
branches = by_search(branches)