diff --git a/Assets/YooAsset/Editor/AssetBundleCollector/AssetBundleCollectorSettingData.cs b/Assets/YooAsset/Editor/AssetBundleCollector/AssetBundleCollectorSettingData.cs
index 5152534..5fd5aee 100644
--- a/Assets/YooAsset/Editor/AssetBundleCollector/AssetBundleCollectorSettingData.cs
+++ b/Assets/YooAsset/Editor/AssetBundleCollector/AssetBundleCollectorSettingData.cs
@@ -27,24 +27,8 @@ namespace YooAsset.Editor
public static bool IsDirty { private set; get; } = false;
- private static AssetBundleCollectorSetting _setting = null;
- public static AssetBundleCollectorSetting Setting
+ static AssetBundleCollectorSettingData()
{
- get
- {
- if (_setting == null)
- LoadSettingData();
- return _setting;
- }
- }
-
- ///
- /// 加载配置文件
- ///
- private static void LoadSettingData()
- {
- _setting = SettingLoader.LoadSettingData();
-
// IPackRule
{
// 清空缓存集合
@@ -147,6 +131,17 @@ namespace YooAsset.Editor
}
}
+ private static AssetBundleCollectorSetting _setting = null;
+ public static AssetBundleCollectorSetting Setting
+ {
+ get
+ {
+ if (_setting == null)
+ _setting = SettingLoader.LoadSettingData();
+ return _setting;
+ }
+ }
+
///
/// 存储配置文件
///
@@ -184,9 +179,6 @@ namespace YooAsset.Editor
public static List GetActiveRuleNames()
{
- if (_setting == null)
- LoadSettingData();
-
List names = new List();
foreach (var pair in _cacheActiveRuleTypes)
{
@@ -199,9 +191,6 @@ namespace YooAsset.Editor
}
public static List GetAddressRuleNames()
{
- if (_setting == null)
- LoadSettingData();
-
List names = new List();
foreach (var pair in _cacheAddressRuleTypes)
{
@@ -214,9 +203,6 @@ namespace YooAsset.Editor
}
public static List GetPackRuleNames()
{
- if (_setting == null)
- LoadSettingData();
-
List names = new List();
foreach (var pair in _cachePackRuleTypes)
{
@@ -229,9 +215,6 @@ namespace YooAsset.Editor
}
public static List GetFilterRuleNames()
{
- if (_setting == null)
- LoadSettingData();
-
List names = new List();
foreach (var pair in _cacheFilterRuleTypes)
{