1
0
mirror of https://github.com/kremalicious/metamask-extension.git synced 2024-10-22 19:26:13 +02:00

Ensure get-first-preferred-lang-code.js matches locale codes from local directory names and chrome extension api.

This commit is contained in:
Dan 2018-04-03 20:34:28 -02:30
parent 69778416ca
commit 5aff114001

View File

@ -2,7 +2,7 @@ const extension = require('extensionizer')
const promisify = require('pify')
const allLocales = require('../../_locales/index.json')
const existingLocaleCodes = allLocales.map(locale => locale.code)
const existingLocaleCodes = allLocales.map(locale => locale.code.replace('_', '-'))
async function getFirstPreferredLangCode () {
const userPreferredLocaleCodes = await promisify(