Commit 1eca4466 authored by Kamil Trzciński's avatar Kamil Trzciński

Merge branch '57223-wiki-finder' into 'master'

Remove BATCH_SIZE from WikiFileFinder

Closes #57223

See merge request gitlab-org/gitlab-ce!24933
parents 1319a9ed b731feba
---
title: Remove BATCH_SIZE from WikiFileFinder
merge_request: 24933
author:
type: other
...@@ -2,8 +2,6 @@ ...@@ -2,8 +2,6 @@
module Gitlab module Gitlab
class WikiFileFinder < FileFinder class WikiFileFinder < FileFinder
BATCH_SIZE = 100
attr_reader :repository attr_reader :repository
def initialize(project, ref) def initialize(project, ref)
...@@ -19,7 +17,7 @@ module Gitlab ...@@ -19,7 +17,7 @@ module Gitlab
safe_query = Regexp.new(safe_query, Regexp::IGNORECASE) safe_query = Regexp.new(safe_query, Regexp::IGNORECASE)
filenames = repository.ls_files(ref) filenames = repository.ls_files(ref)
filenames.grep(safe_query).first(BATCH_SIZE) filenames.grep(safe_query)
end end
end end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment