Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport] Return a String in I18n method 'pluralize' #3307

Merged
merged 1 commit into from
Feb 18, 2019

Conversation

microweb10
Copy link
Member

References

This is a backport of the PR AyuntamientoMadrid#1864

Objectives

If a translation was missing returning a Fixnum could cause to raise an exception "undefined method X for Fixnum".
For instance, we were getting the Exception "ActionView::Template::Error: undefined method 'pluralize' for 1:Fixnum" when calling model_name.human (used by the gem kaminari in the helper method page_entries_info).

If a translation was missing returning a Fixnum was raising an
exception 'undefined method X for Fixnum'.
@microweb10 microweb10 added the Bug label Feb 15, 2019
@microweb10 microweb10 self-assigned this Feb 15, 2019
@microweb10 microweb10 added this to Review in Roadmap Feb 15, 2019
@microweb10 microweb10 changed the title Return a String in I18n method 'pluralize' [Backport] Return a String in I18n method 'pluralize' Feb 15, 2019
@microweb10 microweb10 merged commit d821848 into master Feb 18, 2019
@microweb10 microweb10 deleted the return_string_in_method_pluralize branch February 18, 2019 14:25
@microweb10 microweb10 moved this from Review to Release 0.19 in Roadmap Feb 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants