diff options
-rw-r--r-- | activesupport/lib/active_support/number_helper/number_to_currency_converter.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/activesupport/lib/active_support/number_helper/number_to_currency_converter.rb b/activesupport/lib/active_support/number_helper/number_to_currency_converter.rb index fb5adb574a..ce03700de1 100644 --- a/activesupport/lib/active_support/number_helper/number_to_currency_converter.rb +++ b/activesupport/lib/active_support/number_helper/number_to_currency_converter.rb @@ -29,14 +29,14 @@ module ActiveSupport def options @options ||= begin defaults = default_format_options.merge(i18n_opts) - # Override negative format if format options is given + # Override negative format if format options are given defaults[:negative_format] = "-#{opts[:format]}" if opts[:format] defaults.merge!(opts) end end def i18n_opts - # Set International negative format if not exists + # Set International negative format if it does not exist i18n = i18n_format_options i18n[:negative_format] ||= "-#{i18n[:format]}" if i18n[:format] i18n |