Very using the new api, some older versions are still used.
This commit is contained in:
parent
88817fb9a2
commit
fe7aabc6ea
@ -60,6 +60,7 @@ public class JailIO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** Loads the language file from disk, if there is none then we save the default one. */
|
/** Loads the language file from disk, if there is none then we save the default one. */
|
||||||
|
@SuppressWarnings("deprecation")
|
||||||
public void loadLanguage() {
|
public void loadLanguage() {
|
||||||
String language = pl.getConfig().getString("system.language");
|
String language = pl.getConfig().getString("system.language");
|
||||||
boolean save = false;
|
boolean save = false;
|
||||||
@ -73,13 +74,13 @@ public class JailIO {
|
|||||||
}else {
|
}else {
|
||||||
pl.getLogger().severe("The language file can not be a folder.");
|
pl.getLogger().severe("The language file can not be a folder.");
|
||||||
pl.getLogger().severe("As a result, we are reverting back to English as the language.");
|
pl.getLogger().severe("As a result, we are reverting back to English as the language.");
|
||||||
lang = YamlConfiguration.loadConfiguration(new InputStreamReader(pl.getResource("en.yml")));
|
lang = YamlConfiguration.loadConfiguration(pl.getResource("en.yml"));
|
||||||
save = true;
|
save = true;
|
||||||
}
|
}
|
||||||
}else {
|
}else {
|
||||||
pl.getLogger().warning("Loading the default language of: en");
|
pl.getLogger().warning("Loading the default language of: en");
|
||||||
pl.getLogger().warning("If you wish to change this, please rename 'en.yml' to whatever you wish and set the config value to the name of the file.");
|
pl.getLogger().warning("If you wish to change this, please rename 'en.yml' to whatever you wish and set the config value to the name of the file.");
|
||||||
lang = YamlConfiguration.loadConfiguration(new InputStreamReader(pl.getResource("en.yml")));
|
lang = YamlConfiguration.loadConfiguration(pl.getResource("en.yml"));
|
||||||
save = true;
|
save = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user