Fixes some behavior when a language is valid, but the language file does not exist
This commit is contained in:
parent
650a26402a
commit
98cee192aa
@ -126,13 +126,14 @@ public class LanguageLoader {
|
||||
*/
|
||||
private void readChangedLanguageStrings(InputStream inputStream, String language, Map<String,
|
||||
String> currentLanguageValues) throws IOException {
|
||||
|
||||
//Get language values
|
||||
BufferedReader bufferedReader = FileHelper.getBufferedReaderFromInputStream(inputStream);
|
||||
Map<String, String> internalLanguageValues = FileHelper.readKeyValuePairs(bufferedReader);
|
||||
|
||||
//If currentLanguageValues is null; the chosen language is invalid, use the internal strings instead
|
||||
//If currentLanguageValues is null; the chosen language has not been used before
|
||||
if (currentLanguageValues == null) {
|
||||
updateLanguageFile(language, internalLanguageValues, null);
|
||||
Stargate.logger.info("[stargate] Language (" + language + ") has been loaded");
|
||||
return;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user