Merge branch 'master' of gitlab.com:gitlab-org/gitlab-ce

This commit is contained in:
Dmitriy Zaporozhets 2015-07-09 15:15:45 +02:00
commit 6e0c596a1c
2 changed files with 6 additions and 1 deletions

View File

@ -272,4 +272,8 @@ module ProjectsHelper
current_user.recent_push(@project.id) current_user.recent_push(@project.id)
end end
end end
def readme_cache_key
[@project.id, @project.commit.sha, "readme"].join('-')
end
end end

View File

@ -50,7 +50,8 @@
= link_to namespace_project_edit_blob_path(@project.namespace, @project, tree_join(@repository.root_ref, readme.name)), class: 'light' do = link_to namespace_project_edit_blob_path(@project.namespace, @project, tree_join(@repository.root_ref, readme.name)), class: 'light' do
%i.fa.fa-pencil %i.fa.fa-pencil
.wiki .wiki
= render_readme(readme) = cache(readme_cache_key) do
= render_readme(readme)
- else - else
%h3.page-title %h3.page-title
This project does not have README yet This project does not have README yet