summaryrefslogtreecommitdiff
path: root/electron/src/lib/i18n.js
diff options
context:
space:
mode:
authorLex Neva <lexelby@users.noreply.github.com>2020-04-28 12:34:05 -0400
committerGitHub <noreply@github.com>2020-04-28 18:34:05 +0200
commitcb2b4e3522cb7f426ba5ad3e68deb9e6ccc581ec (patch)
tree2a2f38823c3c9f0b5439ce2aa7c9040299109292 /electron/src/lib/i18n.js
parenteb526927e16954390d06929535d6f5c3766b5f6c (diff)
electron simulator (#531)
Diffstat (limited to 'electron/src/lib/i18n.js')
-rw-r--r--electron/src/lib/i18n.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/electron/src/lib/i18n.js b/electron/src/lib/i18n.js
new file mode 100644
index 00000000..886fd654
--- /dev/null
+++ b/electron/src/lib/i18n.js
@@ -0,0 +1,9 @@
+module.exports.selectLanguage = function () {
+ ['LANGUAGE', 'LC_ALL', 'LC_MESSAGES', 'LANG'].forEach(language => {
+ if (process.env[language]) {
+ return process.env[language].split(":")[0]
+ }
+ })
+
+ return "en_US"
+}