Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMario de la Ossa <mariodelaossa@gmail.com>2019-04-24 20:12:20 +0300
committerMario de la Ossa <mariodelaossa@gmail.com>2019-04-25 23:58:08 +0300
commitd60d50d6baa285d869ab1318c70a3baf0bab2701 (patch)
tree442d2527471fc984f152a570555b86fbe1185b58 /app/views/search
parent8b2592ee744438711f449062ff2dc26101e57833 (diff)
Use wiki partial in search results
Diffstat (limited to 'app/views/search')
-rw-r--r--app/views/search/_results.html.haml5
1 files changed, 2 insertions, 3 deletions
diff --git a/app/views/search/_results.html.haml b/app/views/search/_results.html.haml
index 5b25a67bc87..8ae2807729b 100644
--- a/app/views/search/_results.html.haml
+++ b/app/views/search/_results.html.haml
@@ -21,10 +21,9 @@
- if @scope == 'projects'
.term
= render 'shared/projects/list', projects: @search_objects, pipeline_status: false
- - elsif %w[blobs wiki_blobs].include?(@scope)
- = render partial: 'search/results/blob', collection: @search_objects, locals: { projects: blob_projects(@search_objects) }
- else
- = render partial: "search/results/#{@scope.singularize}", collection: @search_objects
+ - locals = { projects: blob_projects(@search_objects) } if %w[blobs wiki_blobs].include?(@scope)
+ = render partial: "search/results/#{@scope.singularize}", collection: @search_objects, locals: locals
- if @scope != 'projects'
= paginate_collection(@search_objects)