Commit fad353e417a6e7942fca970779a9267794f8daf2
1 parent
6639e83b
Exists in
master
and in
29 other branches
Passing only product to asset_product_extras hotspot
Showing
3 changed files
with
4 additions
and
4 deletions
Show diff stats
app/views/search/_product.rhtml
1 | -<% extra_content = @plugins.dispatch(:asset_product_extras, product, product.enterprise).collect { |content| instance_eval(&content) } %> | |
1 | +<% extra_content = @plugins.dispatch(:asset_product_extras, product).collect { |content| instance_eval(&content) } %> | |
2 | 2 | <% extra_properties = @plugins.dispatch(:asset_product_properties, product)%> |
3 | 3 | |
4 | 4 | <li class="search-product-item"> | ... | ... |
lib/noosfero/plugin.rb
test/functional/search_controller_test.rb
... | ... | @@ -227,13 +227,13 @@ class SearchControllerTest < ActionController::TestCase |
227 | 227 | |
228 | 228 | should 'include extra content supplied by plugins on product asset' do |
229 | 229 | class Plugin1 < Noosfero::Plugin |
230 | - def asset_product_extras(product, enterprise) | |
230 | + def asset_product_extras(product) | |
231 | 231 | lambda {"<span id='plugin1'>This is Plugin1 speaking!</span>"} |
232 | 232 | end |
233 | 233 | end |
234 | 234 | |
235 | 235 | class Plugin2 < Noosfero::Plugin |
236 | - def asset_product_extras(product, enterprise) | |
236 | + def asset_product_extras(product) | |
237 | 237 | lambda {"<span id='plugin2'>This is Plugin2 speaking!</span>"} |
238 | 238 | end |
239 | 239 | end | ... | ... |