diff options
author | Douwe Maan <douwe@selenight.nl> | 2017-06-29 12:06:35 -0500 |
---|---|---|
committer | Douwe Maan <douwe@selenight.nl> | 2017-07-05 11:11:59 -0500 |
commit | fe13f110412d85c05dc68e5ee1db499f681bf722 (patch) | |
tree | 4a2d172bb5a490ac8cadbcf376fbf815393ef22b /app/views/search | |
parent | dc7939337e0d72d2391c3bbb3082d644a54195af (diff) | |
download | gitlab-ce-fe13f110412d85c05dc68e5ee1db499f681bf722.tar.gz |
Create and use project path helpers that only need a project, no namespace
Diffstat (limited to 'app/views/search')
-rw-r--r-- | app/views/search/results/_blob.html.haml | 2 | ||||
-rw-r--r-- | app/views/search/results/_snippet_title.html.haml | 2 | ||||
-rw-r--r-- | app/views/search/results/_wiki_blob.html.haml | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/app/views/search/results/_blob.html.haml b/app/views/search/results/_blob.html.haml index 7f1f807e2e7..de473c23d66 100644 --- a/app/views/search/results/_blob.html.haml +++ b/app/views/search/results/_blob.html.haml @@ -3,7 +3,7 @@ .file-holder .js-file-title.file-title - ref = @search_results.repository_ref - - blob_link = namespace_project_blob_path(@project.namespace, @project, tree_join(ref, file_name)) + - blob_link = project_blob_path(@project, tree_join(ref, file_name)) = link_to blob_link do %i.fa.fa-file %strong diff --git a/app/views/search/results/_snippet_title.html.haml b/app/views/search/results/_snippet_title.html.haml index 026f404ce07..aef825691e0 100644 --- a/app/views/search/results/_snippet_title.html.haml +++ b/app/views/search/results/_snippet_title.html.haml @@ -11,7 +11,7 @@ %small.pull-right.cgray - if snippet_title.project_id? - = link_to snippet_title.project.name_with_namespace, namespace_project_path(snippet_title.project.namespace, snippet_title.project) + = link_to snippet_title.project.name_with_namespace, project_path(snippet_title.project) .snippet-info = snippet_title.to_reference diff --git a/app/views/search/results/_wiki_blob.html.haml b/app/views/search/results/_wiki_blob.html.haml index d87f9df2677..16a0e432d62 100644 --- a/app/views/search/results/_wiki_blob.html.haml +++ b/app/views/search/results/_wiki_blob.html.haml @@ -2,7 +2,7 @@ .blob-result .file-holder .js-file-title.file-title - = link_to namespace_project_wiki_path(@project.namespace, @project, wiki_blob.basename) do + = link_to project_wiki_path(@project, wiki_blob.basename) do %i.fa.fa-file %strong = wiki_blob.basename |