Skip to content

Commit 7efc990

Browse files
committed
some fix
1 parent e3e4e7e commit 7efc990

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/main/java/org/maxgamer/quickshop/localization/text/JavaTextManager.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,13 +100,14 @@ private void reset() {
100100
* @param file The Crowdin file path
101101
* @return The bundled file configuration object
102102
*/
103-
private JsonConfiguration loadBundled(String file) {
103+
private JsonConfiguration loadBundled(String file) throws IOException {
104104
JsonConfiguration bundledLang = new JsonConfiguration();
105+
File fileObject = new File(file);
105106
try {
106-
File fileObject = new File(file);
107107
bundledLang.loadFromString(new String(IOUtils.toByteArray(new InputStreamReader(plugin.getResource("lang/" + fileObject.getName())), StandardCharsets.UTF_8)));
108108
} catch (IOException | InvalidConfigurationException ex) {
109109
bundledLang = new JsonConfiguration();
110+
Util.debugLog(new String(IOUtils.toByteArray(new InputStreamReader(plugin.getResource("lang/" + fileObject.getName())), StandardCharsets.UTF_8)));
110111
plugin.getLogger().log(Level.SEVERE, "Cannot load bundled language file from Jar, some strings may missing!", ex);
111112
}
112113
return bundledLang;

0 commit comments

Comments
 (0)