Fix linting errors in locale/index.js
This commit is contained in:
parent
3b2d68d37d
commit
0612ee64bc
|
@ -8,4 +8,4 @@
|
||||||
karma.config.js
|
karma.config.js
|
||||||
webpack.config.js
|
webpack.config.js
|
||||||
svg.config.js
|
svg.config.js
|
||||||
/app/assets/javascripts/locale/**/*.js
|
/app/assets/javascripts/locale/**/app.js
|
||||||
|
|
|
@ -16,9 +16,8 @@ const locales = allLocales.reduce((d, obj) => {
|
||||||
return data;
|
return data;
|
||||||
}, {});
|
}, {});
|
||||||
|
|
||||||
let lang = document.querySelector('html').getAttribute('lang') || 'en';
|
const langAttribute = document.querySelector('html').getAttribute('lang');
|
||||||
lang = lang.replace(/-/g, '_');
|
const lang = (langAttribute || 'en').replace(/-/g, '_');
|
||||||
|
|
||||||
const locale = new Jed(locales[lang]);
|
const locale = new Jed(locales[lang]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue