aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlystrasz <contact@remyraes.com>2022-08-06 23:26:46 +0200
committerAlystrasz <contact@remyraes.com>2022-08-06 23:26:49 +0200
commit77f7e6fe85c243371c676ec4d4f60de8920d938d (patch)
tree5aaa5824825c22be34b5e123767beeee337b8023 /src
parent26034ec3475a61682a17c95cb2bffdbc9e52af54 (diff)
downloadViper-77f7e6fe85c243371c676ec4d4f60de8920d938d.tar.gz
Viper-77f7e6fe85c243371c676ec4d4f60de8920d938d.zip
feat: translate "impossible to fetch release notes" messages
Diffstat (limited to 'src')
-rw-r--r--src/extras/requests.js5
-rw-r--r--src/lang/en.json5
-rw-r--r--src/lang/fr.json5
3 files changed, 11 insertions, 4 deletions
diff --git a/src/extras/requests.js b/src/extras/requests.js
index 6066e90..7509e9e 100644
--- a/src/extras/requests.js
+++ b/src/extras/requests.js
@@ -2,6 +2,7 @@ const { app } = require("electron");
const path = require("path");
const fs = require("fs");
const { https } = require("follow-redirects");
+const lang = require("../lang");
// all requests results are stored in this file
@@ -120,7 +121,7 @@ async function getNsReleaseNotes() {
resolve( cache[NORTHSTAR_RELEASE_NOTES_KEY]["body"] );
} else {
console.error("Couldn't fetch Northstar release notes, cache is empty.");
- resolve( ["Couldn't fetch Northstar release notes.\nTry again later!"] );
+ resolve( [lang("request.northstar.noReleaseNotes")] );
}
});
}
@@ -171,7 +172,7 @@ async function getVpReleaseNotes() {
resolve( cache[VIPER_RELEASE_NOTES_KEY]["body"] );
} else {
console.error("Couldn't fetch Viper release notes, cache is empty.");
- resolve( ["Couldn't fetch Viper release notes.\nTry again later!"] );
+ resolve( [lang("request.viper.noReleaseNotes")] );
}
});
}
diff --git a/src/lang/en.json b/src/lang/en.json
index d48b3b6..51093fa 100644
--- a/src/lang/en.json
+++ b/src/lang/en.json
@@ -161,5 +161,8 @@
"general.missingpath": "Game location could not be found automatically! Please select it manually!",
"general.notinstalled": "Northstar is not installed!",
"general.launching": "Launching",
- "general.invalidconfig": "Your config file is improperly formatted, if it's been manually edited, please validate that everything is typed correctly.\n\nIf you did not manually edit the config file, it is recommended to simply reset the config.\n\nTo reset your config file simply click \"Ok\" below.\n\nMore details:\n"
+ "general.invalidconfig": "Your config file is improperly formatted, if it's been manually edited, please validate that everything is typed correctly.\n\nIf you did not manually edit the config file, it is recommended to simply reset the config.\n\nTo reset your config file simply click \"Ok\" below.\n\nMore details:\n",
+
+ "request.viper.noReleaseNotes": "Couldn't fetch Viper release notes.\nTry again later!",
+ "request.northstar.noReleaseNotes": "Couldn't fetch Northstar release notes.\nTry again later!"
}
diff --git a/src/lang/fr.json b/src/lang/fr.json
index cd4e4dc..4f819b4 100644
--- a/src/lang/fr.json
+++ b/src/lang/fr.json
@@ -161,5 +161,8 @@
"general.missingpath": "Le chemin du client n'a pu être trouvé automatiquement, merci de le sélectionner manuellement.",
"general.notinstalled": "Northstar n'est pas installé !",
"general.launching": "Lancement",
- "general.invalidconfig": "Votre fichier de configuration n'est pas formaté correctement ; si vous l'avez manuellement édité, veuillez vérifier son contenu.\n\nSinon, il est recommandé de remettre la configuration à zéro.\n\nPour cela, cliquez sur le bouton \"Ok\" en-dessous de ce message.\n\nPlus d'informations :\n"
+ "general.invalidconfig": "Votre fichier de configuration n'est pas formaté correctement ; si vous l'avez manuellement édité, veuillez vérifier son contenu.\n\nSinon, il est recommandé de remettre la configuration à zéro.\n\nPour cela, cliquez sur le bouton \"Ok\" en-dessous de ce message.\n\nPlus d'informations :\n",
+
+ "request.viper.noReleaseNotes": "Impossible de récupérer les notes de mises à jour de Viper.\nVeuillez réessayer plus tard.",
+ "request.northstar.noReleaseNotes": "Impossible de récupérer les notes de mises à jour de Northstar.\nVeuillez réessayer plus tard."
}