summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/views/layouts/header/_default.html.haml2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/layouts/header/_default.html.haml b/app/views/layouts/header/_default.html.haml
index a938a0c70b9..ec1bdf69095 100644
--- a/app/views/layouts/header/_default.html.haml
+++ b/app/views/layouts/header/_default.html.haml
@@ -39,4 +39,4 @@
= render 'shared/outdated_browser'
-if defined?(@project)
:javascript
- var findFileURL = '#{namespace_project_find_file_path(@project.namespace, @project, @ref)}'; \ No newline at end of file
+ var findFileURL = '#{namespace_project_find_file_path(@project.namespace, @project, @ref || @project.repository.root_ref)}'; \ No newline at end of file