FIX: experimental fix to Ember.ENV.EXTEND_PROTOTYPES rare exception (#7133)

This commit is contained in:
Joffrey JAFFEUX 2019-03-08 15:12:13 +01:00 committed by GitHub
parent 0a4562253e
commit 02492679bd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -13,7 +13,7 @@
return oldI18ntoHumanSize.apply(this, [number, options]);
};
if (Ember.ENV.EXTEND_PROTOTYPES) {
if (Ember.typeOf(String.prototype.w) === "function") {
String.prototype.i18n = function(options) {
return I18n.t(String(this), options);
};