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:
authorDouwe Maan <douwe@selenight.nl>2017-03-14 20:58:52 +0300
committerDouwe Maan <douwe@selenight.nl>2017-03-16 18:37:22 +0300
commitc52fead0d2715b27a7f832c8d848a12d3dd84bae (patch)
tree49428e3ff85c2903bdfc5c00cf11f707782d3b29 /app/controllers/projects/blame_controller.rb
parent95b3b6859a150606586854a666b8163bec21a154 (diff)
Fix spec
Diffstat (limited to 'app/controllers/projects/blame_controller.rb')
-rw-r--r--app/controllers/projects/blame_controller.rb5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/controllers/projects/blame_controller.rb b/app/controllers/projects/blame_controller.rb
index 863a766a255..6461eeac11c 100644
--- a/app/controllers/projects/blame_controller.rb
+++ b/app/controllers/projects/blame_controller.rb
@@ -8,9 +8,12 @@ class Projects::BlameController < Projects::ApplicationController
def show
@blob = @repository.blob_at(@commit.id, @path)
-
+
return render_404 unless @blob
+ environment_params = @repository.branch_exists?(@ref) ? { ref: @ref } : { commit: @commit }
+ @environment = EnvironmentsFinder.new(@project, current_user, environment_params).execute.last
+
@blame_groups = Gitlab::Blame.new(@blob, @commit).groups
end
end