From 74b7c6d48e9ca377fe938c8134ed74b612e62ba0 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Wed, 6 Jun 2018 17:37:13 +0200 Subject: Little i18n refractoring --- scripts/i18n/xliff2json.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/i18n/xliff2json.ts b/scripts/i18n/xliff2json.ts index fa5a71d65..c60739561 100755 --- a/scripts/i18n/xliff2json.ts +++ b/scripts/i18n/xliff2json.ts @@ -1,7 +1,7 @@ import * as xliff12ToJs from 'xliff/xliff12ToJs' import { unlink, readFileSync, writeFile } from 'fs' import { join } from 'path' -import { buildFileLocale, I18N_LOCALES, isDefaultLocale } from '../../shared/models/i18n/i18n' +import { buildFileLocale, I18N_LOCALES, isDefaultLocale, LOCALE_FILES } from '../../shared/models/i18n/i18n' import { eachSeries } from 'async' const sources: string[] = [] @@ -9,7 +9,7 @@ const availableLocales = Object.keys(I18N_LOCALES) .filter(l => isDefaultLocale(l) === false) .map(l => buildFileLocale(l)) -for (const file of [ 'server', 'player' ]) { +for (const file of LOCALE_FILES) { for (const locale of availableLocales) { sources.push(join(__dirname, '../../../client/src/locale/target/', `${file}_${locale}.xml`)) } -- cgit v1.2.3