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

Fix Chained backend with KeyValue #407

Merged
merged 1 commit into from Feb 9, 2018

Conversation

@fatkodima
Copy link
Contributor

@fatkodima fatkodima commented Feb 7, 2018

Fixes #405.

With disabled subtrees, when we translate with count and composed key is not found - we cannot easily tell: is "pluralized" key missing or we don't have that key at all. So let raise an I18n::MissingTranslation error and allow the next backend in chain to handle this translation.

This is similar to previous behavior (before #402), except that now it handles pluralized translations.

Correct me if I'm wrong or explained not clearly.

@radar
Copy link
Collaborator

@radar radar commented Feb 7, 2018

Hey @esb, could you please try this PR out on your app and let us know if it fixes the issue that you reported?

@fatkodima fatkodima force-pushed the fatkodima:fix-key-value-subtrees branch from 8929e82 to 852b6e3 Feb 7, 2018
end
value
end

def is_a?(klass)

This comment has been minimized.

@radar

radar Feb 7, 2018
Collaborator

I think the removal of these methods is not connected with this PR. Could you please add them back? I am concerned that it might lead to another regression.

@fatkodima fatkodima force-pushed the fatkodima:fix-key-value-subtrees branch from 852b6e3 to 77c26aa Feb 8, 2018
@esb
Copy link

@esb esb commented Feb 8, 2018

Tested on my application, and it solves the crash problem.

@radar
Copy link
Collaborator

@radar radar commented Feb 9, 2018

Thank you for confirming @esb :)

@radar radar merged commit ba8b206 into ruby-i18n:master Feb 9, 2018
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants