Browse Source

Quick nullref fix

Bond-009 6 năm trước cách đây
mục cha
commit
4625592a83
1 tập tin đã thay đổi với 6 bổ sung5 xóa
  1. 6 5
      MediaBrowser.Controller/Entities/BaseItem.cs

+ 6 - 5
MediaBrowser.Controller/Entities/BaseItem.cs

@@ -36,6 +36,12 @@ namespace MediaBrowser.Controller.Entities
     /// </summary>
     public abstract class BaseItem : IHasProviderIds, IHasLookupInfo<ItemLookupInfo>
     {
+        /// <summary>
+        /// The supported image extensions
+        /// </summary>
+        public static readonly IReadOnlyList<string> SupportedImageExtensions
+            = new [] { ".png", ".jpg", ".jpeg", ".tbn", ".gif" };
+
         private static readonly List<string> _supportedExtensions = new List<string>(SupportedImageExtensions)
         {
             ".nfo",
@@ -69,11 +75,6 @@ namespace MediaBrowser.Controller.Entities
         public static readonly char[] SlugReplaceChars = { '?', '/', '&' };
         public static char SlugChar = '-';
 
-        /// <summary>
-        /// The supported image extensions
-        /// </summary>
-        public static readonly string[] SupportedImageExtensions = { ".png", ".jpg", ".jpeg", ".tbn", ".gif" };
-
         /// <summary>
         /// The trailer folder name
         /// </summary>