Version: 2.1.2 Update
This commit is contained in:
@@ -25,10 +25,6 @@ public class LoadConfig {
|
|||||||
File yamlSetting = new File(SettingPath);
|
File yamlSetting = new File(SettingPath);
|
||||||
if (!(yamlSetting.exists() && yamlSetting.isFile())) {
|
if (!(yamlSetting.exists() && yamlSetting.isFile())) {
|
||||||
initSetting();
|
initSetting();
|
||||||
}
|
|
||||||
|
|
||||||
yamlSetting = new File(ConfigPath);
|
|
||||||
if (!(yamlSetting.exists() && yamlSetting.isFile())) {
|
|
||||||
initRules();
|
initRules();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -71,8 +67,7 @@ public class LoadConfig {
|
|||||||
representer.addClassTag(Config.class, Tag.MAP);
|
representer.addClassTag(Config.class, Tag.MAP);
|
||||||
|
|
||||||
Yaml yaml = new Yaml(new Constructor(),representer,dop);
|
Yaml yaml = new Yaml(new Constructor(),representer,dop);
|
||||||
new LoadConfig();
|
File f = new File(ConfigPath);
|
||||||
File f = new File(getConfigPath());
|
|
||||||
try{
|
try{
|
||||||
Writer ws = new OutputStreamWriter(new FileOutputStream(f), StandardCharsets.UTF_8);
|
Writer ws = new OutputStreamWriter(new FileOutputStream(f), StandardCharsets.UTF_8);
|
||||||
yaml.dump(config,ws);
|
yaml.dump(config,ws);
|
||||||
|
|||||||
Reference in New Issue
Block a user