diff --git a/API/pom.xml b/API/pom.xml index 262ee13..1d4cfa0 100644 --- a/API/pom.xml +++ b/API/pom.xml @@ -5,12 +5,12 @@ ConfigurationMaster com.github.thatsmusic99 - v2.0.0-BETA-2 + v2.0.0-BETA-3 4.0.0 ConfigurationMaster-API - v2.0.0-BETA-3 + v2.0.0-BETA-4 8 @@ -22,7 +22,7 @@ org.yaml snakeyaml - 1.30 + 1.33 provided diff --git a/API/src/main/java/io/github/thatsmusic99/configurationmaster/api/ConfigFile.java b/API/src/main/java/io/github/thatsmusic99/configurationmaster/api/ConfigFile.java index 434e41d..a37509d 100644 --- a/API/src/main/java/io/github/thatsmusic99/configurationmaster/api/ConfigFile.java +++ b/API/src/main/java/io/github/thatsmusic99/configurationmaster/api/ConfigFile.java @@ -42,6 +42,7 @@ public class ConfigFile extends CMConfigSection { private final Yaml yaml; private final DumperOptions yamlOptions = new DumperOptions(); + private final LoaderOptions yamlLoaderOptions = new LoaderOptions(); private final Representer yamlRepresenter = new Representer(); private final File file; private boolean isNew = false; @@ -62,10 +63,11 @@ public class ConfigFile extends CMConfigSection { * @throws YAMLException if the file being loaded contains syntax errors. */ public ConfigFile(@NotNull File file) throws IOException { - yaml = new Yaml(new SafeConstructor(), yamlRepresenter, yamlOptions); + yaml = new Yaml(new SafeConstructor(), yamlRepresenter, yamlOptions, yamlLoaderOptions); yamlOptions.setIndent(2); yamlOptions.setDefaultFlowStyle(DumperOptions.FlowStyle.BLOCK); yamlRepresenter.setDefaultFlowStyle(DumperOptions.FlowStyle.BLOCK); + yamlLoaderOptions.setCodePointLimit(64 * 1024 * 1024); // 64 MB this.file = file; writer = new CommentWriter(this); pendingComments = new ArrayList<>(); diff --git a/Bukkit/pom.xml b/Bukkit/pom.xml index 113afd4..dd542bd 100644 --- a/Bukkit/pom.xml +++ b/Bukkit/pom.xml @@ -22,7 +22,7 @@ org.apache.maven.plugins maven-shade-plugin - 3.3.0-SNAPSHOT + 3.3.0 false false @@ -44,7 +44,7 @@ com.github.thatsmusic99 ConfigurationMaster-API - v2.0.0-BETA-2 + v2.0.0-BETA-3