diff options
author | micael.bergeron <micaelbergeron@gmail.com> | 2017-11-14 11:48:40 -0500 |
---|---|---|
committer | micael.bergeron <micaelbergeron@gmail.com> | 2017-12-07 09:01:23 -0500 |
commit | 6b3f0fee151283348b44a69342ec1a6738cd2de0 (patch) | |
tree | 98f7483a9b5d98d152e268785460d765f1995d13 /app/views/projects/commits | |
parent | e35656318a0ef78a3a4b5257298201fbefe4fbfa (diff) | |
download | gitlab-ce-6b3f0fee151283348b44a69342ec1a6738cd2de0.tar.gz |
corrects the url building
Diffstat (limited to 'app/views/projects/commits')
-rw-r--r-- | app/views/projects/commits/_commit.html.haml | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/app/views/projects/commits/_commit.html.haml b/app/views/projects/commits/_commit.html.haml index 022ded21362..45b4ef12ec9 100644 --- a/app/views/projects/commits/_commit.html.haml +++ b/app/views/projects/commits/_commit.html.haml @@ -4,13 +4,7 @@ - ref = local_assigns.fetch(:ref) { merge_request&.source_branch } - link = commit_path(project, commit, merge_request: merge_request) -- if @note_counts - - note_count = @note_counts.fetch(commit.id, 0) -- else - - notes = commit.notes - - note_count = notes.user.count - -- cache_key = [project.full_path, commit.id, current_application_settings, note_count, @path.presence, current_controller?(:commits), merge_request, I18n.locale] +- cache_key = [project.full_path, commit.id, current_application_settings, @path.presence, current_controller?(:commits), merge_request.iid, view_details, I18n.locale] - cache_key.push(commit.status(ref)) if commit.status(ref) = cache(cache_key, expires_in: 1.day) do @@ -55,4 +49,4 @@ = link_to_browse_code(project, commit) - if view_details && merge_request - = link_to "View details", namespace_project_commit_path(project.namespace, project, commit.id, merge_request_iid: merge_request.iid), class: "btn btn-default" + = link_to "View details", project_commit_path(project, commit.id, merge_request_iid: merge_request.iid), class: "btn btn-default" |