diff --git a/src/main/java/carbonconfiglib/config/ConfigEntry.java b/src/main/java/carbonconfiglib/config/ConfigEntry.java index 3ce917f..83b1048 100644 --- a/src/main/java/carbonconfiglib/config/ConfigEntry.java +++ b/src/main/java/carbonconfiglib/config/ConfigEntry.java @@ -1246,7 +1246,7 @@ public ParseResult canSetArray(List entries) { if(entries == null) return ParseResult.partial(false, NullPointerException::new, "Value isn't allowed to be null"); for(int i = 0,m=entries.size();i result = serializer.deserialize(Helpers.splitArray(entries.get(i), ";")); - if(result.hasError()) return result.onlyError(); + if(result.hasError()) return result.withDefault(false); ParseResult valid = serializer.isValid(result.getValue()); if(valid.hasError()) return valid; } diff --git a/src/main/java/carbonconfiglib/config/ConfigHandler.java b/src/main/java/carbonconfiglib/config/ConfigHandler.java index 66f13a8..0071c8c 100644 --- a/src/main/java/carbonconfiglib/config/ConfigHandler.java +++ b/src/main/java/carbonconfiglib/config/ConfigHandler.java @@ -170,6 +170,7 @@ public void createDefaultConfig() { Path baseFolder = proxy.getBasePaths(createConfigFile(Paths.get(""))); Path file = createConfigFile(baseFolder); if(Files.notExists(file)) { + Helpers.ensureFolder(file.getParent()); save(file); wasSaving--; }