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

Prefer moment's localeData methods #297

Merged

Conversation

drouhard
Copy link
Contributor

@drouhard drouhard commented Feb 7, 2020

The _months, _weekdays, and _weekdaysShort properties suggested in the readme are internal moment.js methods. Using documented, external versions of those (e.g. months()) is less prone to regressions.

This fixes #222 : months show as 'undefined' in Russian

The `_months`, `_weekdays`, and `_weekdaysShort` properties suggested
in the readme are internal momentjs methods. Using the external
versions of those (e.g. `months()`) is less prone to bugs.
@ghost
Copy link

ghost commented Feb 10, 2020

great find @drouhard ! Generally we like tests to assert behavior but given the nature of this change, I think that is unnecessary. One should always prefer public, documented API behavior instead of those quiet lurking _secretThings 😄

@ghost ghost merged commit 9d5a56c into adopted-ember-addons:master Feb 10, 2020
@ghost ghost added the bug label Feb 10, 2020
This pull request was closed.
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.

Month is undefined when using i18n
1 participant