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

Handle false as a key correctly #367

Merged
merged 1 commit into from May 30, 2017
Merged

Conversation

dmeremyanin
Copy link
Contributor

Before this change, I18n.t(false) was always returning false.

@dmeremyanin
Copy link
Contributor Author

Is there something I can do to work towards getting this merged?

@radar radar merged commit 1641e5f into ruby-i18n:master May 30, 2017
@radar
Copy link
Collaborator

radar commented May 30, 2017

Sorry about the delay. I've been busy!

Pinging about it was the right thing to do here. I will now look at doing a new gem release.

@dmeremyanin
Copy link
Contributor Author

Thanks, @radar!

@andrewyoo
Copy link

@radar I think this PR or somewhere >= 0.8.3 broke this:

Handle :default => false correctly
3312ed9

@dmeremyanin
Copy link
Contributor Author

Hey @andrewyoo. Can you please give more details on how to reproduce the issue? It doesn't seem to be broken, all tests are passing for me.

@andrewyoo
Copy link

andrewyoo commented Jun 13, 2017

@dimko

Might be a rails(5.0.3) issue, but here's some detail:

v0.8.3:

[1] pry(main)> I18n.t('key', default: false)
=> false
[2] pry(main)> helper.t('key', default: false)
I18n::MissingTranslationData: translation missing: en.false
from /Users/ayoo/.rbenv/versions/2.4.1/lib/ruby/gems/2.4.0/bundler/gems/i18n-2a388d2d835a/lib/i18n.rb:311:in `handle_exception'

v0.8.2:

[1] pry(main)> I18n.t('key', default: false) 
=> false
[2] pry(main)> helper.t('key', default: false)
=> false

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants