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

Added :default param for I18n.localize #251

Closed
wants to merge 1 commit into from
Closed

Added :default param for I18n.localize #251

wants to merge 1 commit into from

Conversation

fengb
Copy link

@fengb fengb commented Apr 17, 2014

When using I18n.l, there are guards needed when a date is potentially nil:

date && I18n.l(date)
date ? I18n.l(date) : 'present'

This change will return the default when passed in:

I18n.l(date, default: nil)
I18n.l(date, default: 'present')

@radar
Copy link
Collaborator

radar commented Nov 17, 2016

Looks good to me, and a sensible alternative to what was discussed in #294.

I've applied this patch to a branch called pr-251, just to see if the Travis tests will pass there. If they do, then I will merge this to master.

Thanks for your contribution!

@radar radar self-assigned this Nov 17, 2016
@radar radar closed this in 72303d9 Nov 18, 2016
@kiramclean
Copy link

kiramclean commented Dec 8, 2016

I notice a 2 year gap between this code being written and committed.. what's the timeline like for the next release that includes these changes?

@radar
Copy link
Collaborator

radar commented Dec 8, 2016 via email

@kiramclean
Copy link

Awesome. Is there a way to know what issues are blocking release? I'll have some free time over the next few weeks and would be happy to help.

@radar
Copy link
Collaborator

radar commented Dec 9, 2016 via email

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.

3 participants