Tweak the package.json require statement

This commit is contained in:
Peter deHaan 2017-07-30 20:11:12 -07:00
parent 8d1baca60e
commit dff443287c
No known key found for this signature in database
GPG Key ID: F0FC6C01C6305097
1 changed files with 1 additions and 6 deletions

View File

@ -33,12 +33,7 @@ function allLangs() {
} }
function prodLangs() { function prodLangs() {
// eslint-disable-next-line security/detect-non-literal-require return require('../package.json').availableLanguages.join(',');
return require(path.join(
__dirname,
'..',
'package.json'
)).availableLanguages.join(',');
} }
const availableLanguages = conf.l10n_dev ? allLangs() : prodLangs(); const availableLanguages = conf.l10n_dev ? allLangs() : prodLangs();