1
0
mirror of https://e.coding.net/circlecloud/YumCore.git synced 2024-11-22 01:48:50 +00:00

fix: 修复当目录不存在时的报错

Signed-off-by: 502647092 <admin@yumc.pw>
This commit is contained in:
502647092 2016-08-10 10:39:20 +08:00
parent 192245c22c
commit fc940c7b5a

View File

@ -115,6 +115,7 @@ public class Statistics {
public Statistics() { public Statistics() {
try { try {
if (!configfile.exists()) { if (!configfile.exists()) {
configfile.getParentFile().mkdirs();
configfile.createNewFile(); configfile.createNewFile();
} }
config = YamlConfiguration.loadConfiguration(configfile); config = YamlConfiguration.loadConfiguration(configfile);