diff --git a/paper-api/src/main/java/org/bukkit/util/config/Configuration.java b/paper-api/src/main/java/org/bukkit/util/config/Configuration.java index 34d3e09179..ddda68cd37 100644 --- a/paper-api/src/main/java/org/bukkit/util/config/Configuration.java +++ b/paper-api/src/main/java/org/bukkit/util/config/Configuration.java @@ -10,7 +10,15 @@ import java.util.Map; import org.yaml.snakeyaml.DumperOptions; import org.yaml.snakeyaml.Yaml; import org.yaml.snakeyaml.constructor.SafeConstructor; +import org.yaml.snakeyaml.introspector.Property; +import org.yaml.snakeyaml.nodes.CollectionNode; +import org.yaml.snakeyaml.nodes.MappingNode; +import org.yaml.snakeyaml.nodes.Node; +import org.yaml.snakeyaml.nodes.NodeTuple; +import org.yaml.snakeyaml.nodes.SequenceNode; +import org.yaml.snakeyaml.nodes.Tag; import org.yaml.snakeyaml.reader.UnicodeReader; +import org.yaml.snakeyaml.representer.Represent; import org.yaml.snakeyaml.representer.Representer; /** @@ -44,7 +52,6 @@ import org.yaml.snakeyaml.representer.Representer; *
This class is currently incomplete. It is not yet possible to get a node. *
* - * @author sk89q */ public class Configuration extends ConfigurationNode { private Yaml yaml; @@ -58,7 +65,7 @@ public class Configuration extends ConfigurationNode { options.setIndent(4); options.setDefaultFlowStyle(DumperOptions.FlowStyle.BLOCK); - yaml = new Yaml(new SafeConstructor(), new Representer(), options); + yaml = new Yaml(new SafeConstructor(), new EmptyNullRepresenter(), options); this.file = file; } @@ -136,3 +143,41 @@ public class Configuration extends ConfigurationNode { return new ConfigurationNode(new HashMap