diff --git a/src/main/java/com/graywolf336/jail/JailIO.java b/src/main/java/com/graywolf336/jail/JailIO.java index a6a9834..924512e 100644 --- a/src/main/java/com/graywolf336/jail/JailIO.java +++ b/src/main/java/com/graywolf336/jail/JailIO.java @@ -60,6 +60,7 @@ public class JailIO { } /** Loads the language file from disk, if there is none then we save the default one. */ + @SuppressWarnings("deprecation") public void loadLanguage() { String language = pl.getConfig().getString("system.language"); boolean save = false; @@ -73,13 +74,13 @@ public class JailIO { }else { 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."); - lang = YamlConfiguration.loadConfiguration(new InputStreamReader(pl.getResource("en.yml"))); + lang = YamlConfiguration.loadConfiguration(pl.getResource("en.yml")); save = true; } }else { 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."); - lang = YamlConfiguration.loadConfiguration(new InputStreamReader(pl.getResource("en.yml"))); + lang = YamlConfiguration.loadConfiguration(pl.getResource("en.yml")); save = true; }