save sentry from this

This commit is contained in:
Maikiwi 2022-07-31 19:02:43 -07:00
parent b4b6b0f988
commit a99dd1b17d

View file

@ -90,7 +90,8 @@ export class utils {
if (language !== "en_US" && fs.existsSync(path.join(this.paths.i18nPath, `${language}.json`))) {
i18n = Object.assign(i18n, JSON.parse(fs.readFileSync(path.join(this.paths.i18nPath, `${language}.json`), "utf8")));
} else if (!fs.existsSync(path.join(this.paths.i18nPath, `${language}.json`))) {
}
/* else if (!fs.existsSync(path.join(this.paths.i18nPath, `${language}.json`))) {
fetch(`https://raw.githubusercontent.com/ciderapp/Cider/main/src/i18n/${language}.json`)
.then(res => res.json())
.then(res => {
@ -101,7 +102,8 @@ export class utils {
i18n = Object.assign(i18n, JSON.parse(fs.readFileSync(path.join(this.paths.i18nPath, `en_US.json`), "utf8")));
}
})
}
} */
if (key) {
return i18n[key]
} else {