Commit bd7dc72749f8351851600a807d3866f7d995650a
1 parent
5db7f142
Exists in
master
and in
3 other branches
Fix search controller to stop breaking the core tests
Signed-off-by: Gabriela Navarro <navarro1703@gmail.com>
Showing
1 changed file
with
5 additions
and
4 deletions
Show diff stats
lib/ext/search_controller.rb
| ... | ... | @@ -3,10 +3,11 @@ require_dependency 'search_controller' |
| 3 | 3 | class SearchController |
| 4 | 4 | |
| 5 | 5 | def communities |
| 6 | - results = filter_communities_list do |community| | |
| 7 | - !community.institution? | |
| 8 | - end | |
| 9 | - results = results.paginate(:per_page => 24, :page => params[:page]) | |
| 6 | + @scope = visible_profiles(Community) | |
| 7 | + full_text_search | |
| 8 | + results = @searches[@asset][:results] | |
| 9 | + | |
| 10 | + results = results.each {|community| !community.institution?} | |
| 10 | 11 | @searches[@asset] = {:results => results} |
| 11 | 12 | @search = results |
| 12 | 13 | end | ... | ... |