فهرست منبع

数据缓存时报空

lin5 8 سال پیش
والد
کامیت
22b5cd4432
1فایلهای تغییر یافته به همراه3 افزوده شده و 3 حذف شده
  1. 3 3
      Server/Model/Component/DBCacheComponent.cs

+ 3 - 3
Server/Model/Component/DBCacheComponent.cs

@@ -37,7 +37,7 @@ namespace Model
 
 			this.AddToCache(disposer, collectionName);
 
-			if (collectionName == "")
+			if (string.IsNullOrEmpty(collectionName))
 			{
 				collectionName = disposer.GetType().Name;
 			}
@@ -57,7 +57,7 @@ namespace Model
 
 		public void AddToCache(Disposer disposer, string collectionName = "")
 		{
-			if (collectionName == "")
+			if (string.IsNullOrEmpty(collectionName))
 			{
 				collectionName = disposer.GetType().Name;
 			}
@@ -147,4 +147,4 @@ namespace Model
 			return tcs.Task;
 		}
 	}
-}
+}