Commit 01024be25b6399b65963395ff36af137489ff33a
1 parent
d03ee223
Exists in
master
and in
26 other branches
Revert "search: on crash, don't let exception load all data"
This reverts commit 82742464704b48dce6337fa31610da3db7a6bce4. This commit broke searches pagination when using solr
Showing
1 changed file
with
3 additions
and
3 deletions
Show diff stats
app/controllers/public/search_controller.rb
| @@ -61,7 +61,7 @@ class SearchController < PublicController | @@ -61,7 +61,7 @@ class SearchController < PublicController | ||
| 61 | end | 61 | end |
| 62 | 62 | ||
| 63 | def articles | 63 | def articles |
| 64 | - @scope = @environment.articles.public.paginate(paginate_options) | 64 | + @scope = @environment.articles.public |
| 65 | full_text_search | 65 | full_text_search |
| 66 | end | 66 | end |
| 67 | 67 | ||
| @@ -75,7 +75,7 @@ class SearchController < PublicController | @@ -75,7 +75,7 @@ class SearchController < PublicController | ||
| 75 | end | 75 | end |
| 76 | 76 | ||
| 77 | def products | 77 | def products |
| 78 | - @scope = @environment.products.paginate(paginate_options) | 78 | + @scope = @environment.products |
| 79 | full_text_search | 79 | full_text_search |
| 80 | end | 80 | end |
| 81 | 81 | ||
| @@ -238,7 +238,7 @@ class SearchController < PublicController | @@ -238,7 +238,7 @@ class SearchController < PublicController | ||
| 238 | def visible_profiles(klass, *extra_relations) | 238 | def visible_profiles(klass, *extra_relations) |
| 239 | relations = [:image, :domains, :environment, :preferred_domain] | 239 | relations = [:image, :domains, :environment, :preferred_domain] |
| 240 | relations += extra_relations | 240 | relations += extra_relations |
| 241 | - @environment.send(klass.name.underscore.pluralize).visible.includes(relations).paginate(paginate_options) | 241 | + @environment.send(klass.name.underscore.pluralize).visible.includes(relations) |
| 242 | end | 242 | end |
| 243 | 243 | ||
| 244 | def per_page | 244 | def per_page |