summaryrefslogtreecommitdiff
path: root/app/controllers/projects/tree_controller.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/controllers/projects/tree_controller.rb')
-rw-r--r--app/controllers/projects/tree_controller.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/app/controllers/projects/tree_controller.rb b/app/controllers/projects/tree_controller.rb
index f3719059f88..2998ec21dca 100644
--- a/app/controllers/projects/tree_controller.rb
+++ b/app/controllers/projects/tree_controller.rb
@@ -26,7 +26,10 @@ class Projects::TreeController < Projects::ApplicationController
respond_to do |format|
format.html do
+ blob_ids = tree.blobs.map(&:id)
+
@last_commit = @repository.last_commit_for_path(@commit.id, @tree.path) || @commit
+ @lfs_blob_ids = Gitlab::Git::Blob.batch_lfs_pointers(@repo, blob_ids).map(&:id)
end
format.js do