浏览代码

Merge pull request #2434 from Bond-009/photo

Fix photo serialization
dkanada 5 年之前
父节点
当前提交
557b165f01
共有 1 个文件被更改,包括 3 次插入5 次删除
  1. 3 5
      MediaBrowser.Controller/Entities/Photo.cs

+ 3 - 5
MediaBrowser.Controller/Entities/Photo.cs

@@ -41,10 +41,10 @@ namespace MediaBrowser.Controller.Entities
         public override double GetDefaultPrimaryImageAspectRatio()
         {
             // REVIEW: @bond
-            if (Width.HasValue && Height.HasValue)
+            if (Width != 0 && Height != 0)
             {
-                double width = Width.Value;
-                double height = Height.Value;
+                double width = Width;
+                double height = Height;
 
                 if (Orientation.HasValue)
                 {
@@ -67,8 +67,6 @@ namespace MediaBrowser.Controller.Entities
             return base.GetDefaultPrimaryImageAspectRatio();
         }
 
-        public new int? Width { get; set; }
-        public new int? Height { get; set; }
         public string CameraMake { get; set; }
         public string CameraModel { get; set; }
         public string Software { get; set; }