diff options
author | Phil Hughes <me@iamphill.com> | 2017-11-06 10:51:44 +0000 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-11-06 10:52:04 +0000 |
commit | bd5ea484952e3ee4c50b7ffeaa20801696222ed2 (patch) | |
tree | 3c47c431d2424d0f3421b6cf8fe10bce0fe284e6 | |
parent | eacd821a3c0bae80a56a6933d5ab6aea4b9f283e (diff) | |
download | gitlab-ce-bd5ea484952e3ee4c50b7ffeaa20801696222ed2.tar.gz |
fixed karma testmulti-file-editor-separate-commits-call
updated controller based on review
-rw-r--r-- | app/assets/javascripts/vue_shared/components/skeleton_loading_container.vue | 2 | ||||
-rw-r--r-- | app/controllers/projects/refs_controller.rb | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/app/assets/javascripts/vue_shared/components/skeleton_loading_container.vue b/app/assets/javascripts/vue_shared/components/skeleton_loading_container.vue index 7ab5e069003..b06493e6c66 100644 --- a/app/assets/javascripts/vue_shared/components/skeleton_loading_container.vue +++ b/app/assets/javascripts/vue_shared/components/skeleton_loading_container.vue @@ -14,7 +14,7 @@ }, computed: { lineClasses() { - return new Array(this.lines).fill().map((_, i) => `skeleton-line-${i}`); + return new Array(this.lines).fill().map((_, i) => `skeleton-line-${i + 1}`); }, }, }; diff --git a/app/controllers/projects/refs_controller.rb b/app/controllers/projects/refs_controller.rb index 82f7ccb6afa..2376f469213 100644 --- a/app/controllers/projects/refs_controller.rb +++ b/app/controllers/projects/refs_controller.rb @@ -56,11 +56,12 @@ class Projects::RefsController < Projects::ApplicationController contents[@offset, @limit].to_a.map do |content| file = @path ? File.join(@path, content.name) : content.name last_commit = @repo.last_commit_for_path(@commit.id, file) + commit_path = project_commit_path(@project, last_commit) if last_commit { file_name: content.name, commit: last_commit, type: content.type, - commit_path: (project_commit_path(@project, last_commit) unless last_commit.nil?) + commit_path: commit_path } end end |