minor fixes

* jfoenix 9.0.1 -> 9.0.2
This commit is contained in:
Jannik
2018-03-11 15:49:56 +01:00
parent 81a79100fc
commit 6282c8ce98
2 changed files with 6 additions and 5 deletions

View File

@ -955,8 +955,9 @@ public class MainWindowController {
// try loading the omdbAPI key
try {
File file = new File(getClass().getClassLoader().getResource("apiKeys.json").getFile());
JsonObject apiKeys = Json.parse(new FileReader(file)).asObject();
InputStream in = getClass().getClassLoader().getResourceAsStream("apiKeys.json");
BufferedReader reader = new BufferedReader(new InputStreamReader(in));
JsonObject apiKeys = Json.parse(reader).asObject();
omdbAPIKey = apiKeys.getString("omdbAPIKey", "");
} catch (Exception e) {
LOGGER.error("Cloud not load the omdbAPI key. Please contact the developer!", e);