diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-22 06:08:17 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-06-22 06:08:17 +0300 |
commit | 1127990db899d0fb36c900c81857ff6107e611d4 (patch) | |
tree | d704d0c91b9a91815cc7e9b9fb1f09c722b2eda4 /app/controllers | |
parent | 4584816f15e57af3fbbf1d1280b691549384e1aa (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/projects/blob_controller.rb | 2 | ||||
-rw-r--r-- | app/controllers/projects/tree_controller.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/projects/blob_controller.rb b/app/controllers/projects/blob_controller.rb index abc1d58cbf1..804f1db4721 100644 --- a/app/controllers/projects/blob_controller.rb +++ b/app/controllers/projects/blob_controller.rb @@ -214,7 +214,7 @@ class Projects::BlobController < Projects::ApplicationController environment_params = @repository.branch_exists?(@ref) ? { ref: @ref } : { commit: @commit } environment_params[:find_latest] = true @environment = EnvironmentsFinder.new(@project, current_user, environment_params).execute.last - @last_commit = @repository.last_commit_for_path(@commit.id, @blob.path) + @last_commit = @repository.last_commit_for_path(@commit.id, @blob.path, literal_pathspec: true) @code_navigation_path = Gitlab::CodeNavigationPath.new(@project, @blob.commit_id).full_json_path_for(@blob.path) render 'show' diff --git a/app/controllers/projects/tree_controller.rb b/app/controllers/projects/tree_controller.rb index 9cb345724cc..b4925cd2774 100644 --- a/app/controllers/projects/tree_controller.rb +++ b/app/controllers/projects/tree_controller.rb @@ -34,7 +34,7 @@ class Projects::TreeController < Projects::ApplicationController format.html do lfs_blob_ids if Feature.disabled?(:vue_file_list, @project, default_enabled: true) - @last_commit = @repository.last_commit_for_path(@commit.id, @tree.path) || @commit + @last_commit = @repository.last_commit_for_path(@commit.id, @tree.path, literal_pathspec: true) || @commit end end end |