Commit 70e59035 authored by Jacob Schatz's avatar Jacob Schatz

Fix project find url so branch ref is not nil

Also adds autocomplete="off" to find input.
parent 47846958
......@@ -37,6 +37,10 @@
%h1.title= title
= render 'shared/outdated_browser'
- if @project
-if @project && !@project.empty_repo? && @ref
:javascript
var findFileURL = '#{namespace_project_find_file_path(@project.namespace, @project, @ref || @project.repository.root_ref)}';
\ No newline at end of file
var findFileURL = '#{namespace_project_find_file_path(@project.namespace, @project, @ref)}';
-elsif @project && !@project.empty_repo?
:javascript
var findFileURL = '#{namespace_project_find_file_path(@project.namespace, @project, @project.repository.root_ref)}';
\ No newline at end of file
......@@ -10,7 +10,7 @@
= link_to namespace_project_tree_path(@project.namespace, @project, @ref) do
= @project.path
%li.file-finder
%input#file_find.form-control.file-finder-input{type: "text", placeholder: 'Find by path'}
%input#file_find.form-control.file-finder-input{type: "text", placeholder: 'Find by path', autocomplete: 'off'}
%div.tree-content-holder
.table-holder
......
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