1
mirror of https://github.com/CarmJos/MineSQL.git synced 2026-06-05 00:48:16 +08:00

完善Properties读取与初始化

This commit is contained in:
2022-02-24 04:47:33 +08:00
parent 869a5df1fd
commit 7511125648
2 changed files with 17 additions and 3 deletions
@@ -1,5 +1,6 @@
package cc.carm.plugin.easysql.util;
import cc.carm.plugin.easysql.util.JarResourceUtils;
import org.jetbrains.annotations.NotNull;
import java.io.File;
@@ -14,7 +15,7 @@ public class DBPropertiesUtil {
public static Map<String, Properties> readFromFolder(File propertiesFolder) {
Map<String, Properties> propertiesMap = new HashMap<>();
if (!propertiesFolder.isDirectory()) return propertiesMap;
if (!propertiesFolder.exists() || !propertiesFolder.isDirectory()) return propertiesMap;
File[] files = propertiesFolder.listFiles();
if (files == null || files.length == 0) return propertiesMap;