Skip to content

Commit 4c99438

Browse files
committed
Set YAML flow style to BLOCK in VelocityYMLFile
1 parent 068a069 commit 4c99438

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

SimpleAPI/src/main/java/com/bencodez/simpleapi/file/velocity/VelocityYMLFile.java

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
import java.util.ArrayList;
66
import java.util.List;
77

8+
import org.yaml.snakeyaml.DumperOptions;
9+
810
import com.google.common.reflect.TypeToken;
911

1012
import lombok.Getter;
@@ -34,7 +36,8 @@ public VelocityYMLFile(File file) {
3436
e.printStackTrace();
3537
}
3638
}
37-
loader = YAMLConfigurationLoader.builder().setPath(file.toPath()).build();
39+
loader = YAMLConfigurationLoader.builder().setFlowStyle(DumperOptions.FlowStyle.BLOCK).setPath(file.toPath())
40+
.build();
3841

3942
try {
4043
conf = loader.load();
@@ -86,7 +89,8 @@ public List<String> getStringList(ConfigurationNode node, ArrayList<String> def)
8689
}
8790

8891
public void reload() {
89-
loader = YAMLConfigurationLoader.builder().setPath(file.toPath()).build();
92+
loader = YAMLConfigurationLoader.builder().setFlowStyle(DumperOptions.FlowStyle.BLOCK).setPath(file.toPath())
93+
.build();
9094

9195
try {
9296
conf = loader.load();

0 commit comments

Comments
 (0)