diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-29 12:08:46 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-07-29 12:08:46 +0300 |
commit | f931527bc5120097db15737f8594a431bcad9116 (patch) | |
tree | 9f222683bb0ee7b88e3f7c0e02362a530e3c98a6 /app/models/tree.rb | |
parent | fd3d0d4c2c5ecac651fdeff92a1f2e4c927e05e0 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/models/tree.rb')
-rw-r--r-- | app/models/tree.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/tree.rb b/app/models/tree.rb index cd385872171..fd416ebdedc 100644 --- a/app/models/tree.rb +++ b/app/models/tree.rb @@ -4,9 +4,9 @@ class Tree include Gitlab::MarkupHelper include Gitlab::Utils::StrongMemoize - attr_accessor :repository, :sha, :path, :entries + attr_accessor :repository, :sha, :path, :entries, :cursor - def initialize(repository, sha, path = '/', recursive: false) + def initialize(repository, sha, path = '/', recursive: false, pagination_params: nil) path = '/' if path.blank? @repository = repository @@ -14,7 +14,7 @@ class Tree @path = path git_repo = @repository.raw_repository - @entries = Gitlab::Git::Tree.where(git_repo, @sha, @path, recursive) + @entries, @cursor = Gitlab::Git::Tree.where(git_repo, @sha, @path, recursive, pagination_params) end def readme_path |