Commit f1feed0c by shaileshparamisoft Committed by Jon Yurek

Fixed the number helper condition issue

parent 24aa94dc
...@@ -71,7 +71,7 @@ module Paperclip ...@@ -71,7 +71,7 @@ module Paperclip
end end
def human_size(size) def human_size(size)
if defined?(ActiveRecord::NumberHelper) # Rails 4.0+ if defined?(ActiveSupport::NumberHelper) # Rails 4.0+
ActiveSupport::NumberHelper.number_to_human_size(size) ActiveSupport::NumberHelper.number_to_human_size(size)
else else
storage_units_format = I18n.translate(:'number.human.storage_units.format', :locale => options[:locale], :raise => true) storage_units_format = I18n.translate(:'number.human.storage_units.format', :locale => options[:locale], :raise => true)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment