Browse Source

Further fix to LoggablePropertyAttribute serialization

Frank van den Bos 2 năm trước cách đây
mục cha
commit
53b101211f
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      InABox.Core/DataTable.cs

+ 2 - 2
InABox.Core/DataTable.cs

@@ -826,9 +826,9 @@ namespace InABox.Core
             {
                 writer.Write(time.Ticks);
             }
-            else if (type == typeof(LoggablePropertyAttribute) && value is LoggablePropertyAttribute lpa)
+            else if (type == typeof(LoggablePropertyAttribute))
             {
-                writer.Write(lpa.Format ?? "");
+                writer.Write((value as LoggablePropertyAttribute)?.Format ?? "");
             }
             else
             {