Return a String in I18n method 'pluralize'

If a translation was missing returning a Fixnum was raising an
exception 'undefined method X for Fixnum'.
This commit is contained in:
Julian Herrero
2019-02-07 10:54:28 +01:00
parent 4a12425987
commit 366505f886
3 changed files with 22 additions and 3 deletions

View File

@@ -16,5 +16,6 @@
# end
ActiveSupport::Inflector.inflections(:en) do |inflect|
inflect.plural(/^(\d+)$/i, '\1')
inflect.irregular 'organización', 'organizaciones'
end