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:
authorPhil Hughes <me@iamphill.com>2017-11-01 19:08:06 +0300
committerPhil Hughes <me@iamphill.com>2017-11-06 13:52:02 +0300
commit054200062f1151fd31138305721d04798e8880b7 (patch)
treef46976e5dd0eadc5de8c2202571520dfc5b31661 /app/controllers/projects/refs_controller.rb
parentd4ceec9d47a7da5fa17cb6e161ac491e13fcb8bd (diff)
Multi-file editor fetch log data from a different endpoint
Closes #38360
Diffstat (limited to 'app/controllers/projects/refs_controller.rb')
-rw-r--r--app/controllers/projects/refs_controller.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/app/controllers/projects/refs_controller.rb b/app/controllers/projects/refs_controller.rb
index 2fd015df688..e5285ca8fba 100644
--- a/app/controllers/projects/refs_controller.rb
+++ b/app/controllers/projects/refs_controller.rb
@@ -58,7 +58,8 @@ class Projects::RefsController < Projects::ApplicationController
last_commit = @repo.last_commit_for_path(@commit.id, file)
{
file_name: content.name,
- commit: last_commit
+ commit: last_commit,
+ type: content.type
}
end
end
@@ -70,6 +71,11 @@ class Projects::RefsController < Projects::ApplicationController
respond_to do |format|
format.html { render_404 }
+ format.json do
+ response.headers["Log-Url"] = @more_log_url
+
+ render json: @logs
+ end
format.js
end
end