瀏覽代碼

Use array instead of HashSet

Cody Robibero 3 年之前
父節點
當前提交
87439665d7
共有 1 個文件被更改,包括 7 次插入7 次删除
  1. 7 7
      Emby.Server.Implementations/Data/SqliteItemRepository.cs

+ 7 - 7
Emby.Server.Implementations/Data/SqliteItemRepository.cs

@@ -196,7 +196,7 @@ namespace Emby.Server.Implementations.Data
 
         private static readonly string _mediaAttachmentInsertPrefix;
 
-        private static readonly HashSet<BaseItemKind> _programTypes = new()
+        private static readonly BaseItemKind[] _programTypes = new[]
         {
             BaseItemKind.Program,
             BaseItemKind.TvChannel,
@@ -204,7 +204,7 @@ namespace Emby.Server.Implementations.Data
             BaseItemKind.LiveTvChannel
         };
 
-        private static readonly HashSet<BaseItemKind> _programExcludeParentTypes = new()
+        private static readonly BaseItemKind[] _programExcludeParentTypes = new[]
         {
             BaseItemKind.Series,
             BaseItemKind.Season,
@@ -213,19 +213,19 @@ namespace Emby.Server.Implementations.Data
             BaseItemKind.PhotoAlbum
         };
 
-        private static readonly HashSet<BaseItemKind> _serviceTypes = new()
+        private static readonly BaseItemKind[] _serviceTypes = new[]
         {
             BaseItemKind.TvChannel,
             BaseItemKind.LiveTvChannel
         };
 
-        private static readonly HashSet<BaseItemKind> _startDateTypes = new()
+        private static readonly BaseItemKind[] _startDateTypes = new[]
         {
             BaseItemKind.Program,
             BaseItemKind.LiveTvProgram
         };
 
-        private static readonly HashSet<BaseItemKind> _seriesTypes = new()
+        private static readonly BaseItemKind[] _seriesTypes = new[]
         {
             BaseItemKind.Book,
             BaseItemKind.AudioBook,
@@ -233,14 +233,14 @@ namespace Emby.Server.Implementations.Data
             BaseItemKind.Season
         };
 
-        private static readonly HashSet<BaseItemKind> _artistExcludeParentTypes = new()
+        private static readonly BaseItemKind[] _artistExcludeParentTypes = new[]
         {
             BaseItemKind.Series,
             BaseItemKind.Season,
             BaseItemKind.PhotoAlbum
         };
 
-        private static readonly HashSet<BaseItemKind> _artistsTypes = new()
+        private static readonly BaseItemKind[] _artistsTypes = new[]
         {
             BaseItemKind.Audio,
             BaseItemKind.MusicAlbum,