From ca034bbc10166d68c3b3fa3c07eea5c16118a12a Mon Sep 17 00:00:00 2001 From: Ashu Date: Wed, 23 Oct 2024 21:50:18 -0300 Subject: [PATCH] =?UTF-8?q?=E2=9C=8D=EF=B8=8F=20Always=20overwrite=20trans?= =?UTF-8?q?lation=20files?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/src/controller/lang.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/core/src/controller/lang.ts b/core/src/controller/lang.ts index df2dae2..904352b 100644 --- a/core/src/controller/lang.ts +++ b/core/src/controller/lang.ts @@ -38,10 +38,8 @@ export class Lang { const content = languages[lang] const externalPath = join(RootPATH, 'locales', dirname(lang.split('/')[0]), lang) - if (!(await exists(externalPath))) { - await mkdir(externalPath, { recursive: true }).catch(() => undefined) - await writeFile(join(externalPath, '/translation.json'), JSON.stringify(content, null, 2), { encoding: 'utf8' }) - } + await mkdir(externalPath, { recursive: true }).catch(() => undefined) + await writeFile(join(externalPath, '/translation.json'), JSON.stringify(content, null, 2), { encoding: 'utf8' }) } }