Explorar o código

Fix InvalidOperationException when serializing MediaPathInfo

Bond_009 %!s(int64=3) %!d(string=hai) anos
pai
achega
b458f85c47
Modificáronse 1 ficheiros con 6 adicións e 0 borrados
  1. 6 0
      MediaBrowser.Model/Configuration/MediaPathInfo.cs

+ 6 - 0
MediaBrowser.Model/Configuration/MediaPathInfo.cs

@@ -9,6 +9,12 @@ namespace MediaBrowser.Model.Configuration
             Path = path;
         }
 
+        // Needed for xml serialization
+        public MediaPathInfo()
+        {
+            Path = string.Empty;
+        }
+
         public string Path { get; set; }
 
         public string? NetworkPath { get; set; }