diff --git a/src/main/java/us/tastybento/bskyblock/api/localization/BSBLocale.java b/src/main/java/us/tastybento/bskyblock/api/localization/BSBLocale.java index 3afe9d489..95f4fee56 100644 --- a/src/main/java/us/tastybento/bskyblock/api/localization/BSBLocale.java +++ b/src/main/java/us/tastybento/bskyblock/api/localization/BSBLocale.java @@ -15,12 +15,10 @@ public class BSBLocale { private Locale locale; private YamlConfiguration config; - private Map cache; public BSBLocale(Locale locale, File file) { this.locale = locale; this.config = YamlConfiguration.loadConfiguration(file); - this.cache = new HashMap<>(); } /** @@ -29,19 +27,12 @@ public class BSBLocale { * @return Text for this locale reference or the reference if nothing has been found */ public String get(String reference) { - if (cache.containsKey(reference)) { - return cache.get(reference); - } else if (config.contains(reference)) { - cache.put(reference, ChatColor.translateAlternateColorCodes('&', config.getString(reference))); - return cache.get(reference); + if (config.contains(reference)) { + return config.getString(reference); } return reference; // return reference in case nothing has been found } - public void clearCache() { - this.cache.clear(); - } - /** * Returns the locale language * @return the locale language