ソースを参照

Further fix to LoggablePropertyAttribute serialization

Frank van den Bos 2 年 前
コミット
53b101211f
1 ファイル変更2 行追加2 行削除
  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
             {