Commit 3083e5e4 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Hide new file link if not branch HEAD

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent 160bd862
......@@ -10,6 +10,7 @@
= link_to truncate(title, length: 40), project_tree_path(@project, path)
- else
= link_to title, '#'
- if @repository.branch_names.include?(@ref)
\/
%li
= link_to project_new_tree_path(@project, @id), title: 'New file', id: 'new-file-link' do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment