Skip to content

Commit

Permalink
fixing sum of methods
Browse files Browse the repository at this point in the history
  • Loading branch information
flvorful committed Nov 3, 2009
1 parent a6e6ddc commit 33e77fa
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions lib/super_inplace_controls.rb
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,7 @@ def set_final_text(object, attribute, options)
end.join(", ")
else
methods = options[:final_text]
methods.inject(@item) { |sum_of_methods, meth| sum_of_methods = sum_of_methods.send(meth) }
@final_text = sum_of_methods
@final_text = methods.inject(@item) { |sum_of_methods, meth| sum_of_methods = sum_of_methods.send(meth) }
end
@final_text
else
Expand Down

0 comments on commit 33e77fa

Please sign in to comment.