Commit a000aad02d49a47755e9a14699af35c87704795b
Exists in
master
and in
29 other branches
Merge commit 'refs/merge-requests/354' of git://gitorious.org/noosfero/noosfero into stable
Showing
1 changed file
with
2 additions
and
4 deletions
Show diff stats
plugins/solr/lib/solr_plugin/search_helper.rb
@@ -34,10 +34,6 @@ module SolrPlugin::SearchHelper | @@ -34,10 +34,6 @@ module SolrPlugin::SearchHelper | ||
34 | ], | 34 | ], |
35 | } | 35 | } |
36 | 36 | ||
37 | -# def asset_class(asset) | ||
38 | -# asset.to_s.singularize.camelize.constantize | ||
39 | -# end | ||
40 | - | ||
41 | def class_asset(klass) | 37 | def class_asset(klass) |
42 | klass.name.underscore.pluralize.to_sym | 38 | klass.name.underscore.pluralize.to_sym |
43 | end | 39 | end |
@@ -111,6 +107,8 @@ module SolrPlugin::SearchHelper | @@ -111,6 +107,8 @@ module SolrPlugin::SearchHelper | ||
111 | 107 | ||
112 | def asset_class(asset) | 108 | def asset_class(asset) |
113 | asset.to_s.singularize.camelize.constantize | 109 | asset.to_s.singularize.camelize.constantize |
110 | + rescue | ||
111 | + asset.to_s.singularize.camelize.gsub('Plugin', 'Plugin::').constantize | ||
114 | end | 112 | end |
115 | 113 | ||
116 | def set_facets_variables | 114 | def set_facets_variables |