about summary refs log tree commit diff
path: root/LibMatrix/Responses/SyncResponse.cs
diff options
context:
space:
mode:
authorEmma [it/its]@Rory& <root@rory.gay>2024-01-05 12:22:42 +0100
committerEmma [it/its]@Rory& <root@rory.gay>2024-01-05 12:22:42 +0100
commitf215dca816745ef54f5436d6cea9350d6dcd3982 (patch)
tree2749bcd4d1297943478b6080d5688ef642ca1d40 /LibMatrix/Responses/SyncResponse.cs
parentToObject and ToJson for MatrixException (diff)
downloadLibMatrix-f215dca816745ef54f5436d6cea9350d6dcd3982.tar.xz
Cleanup
Diffstat (limited to 'LibMatrix/Responses/SyncResponse.cs')
-rw-r--r--LibMatrix/Responses/SyncResponse.cs6
1 files changed, 5 insertions, 1 deletions
diff --git a/LibMatrix/Responses/SyncResponse.cs b/LibMatrix/Responses/SyncResponse.cs
index 42759ff..49259d0 100644
--- a/LibMatrix/Responses/SyncResponse.cs
+++ b/LibMatrix/Responses/SyncResponse.cs
@@ -2,6 +2,10 @@ using System.Text.Json.Serialization;
 
 namespace LibMatrix.Responses;
 
+[JsonSourceGenerationOptions(WriteIndented = true)]
+[JsonSerializable(typeof(SyncResponse))]
+internal partial class SyncResponseSerializerContext : JsonSerializerContext { }
+
 public class SyncResponse {
     [JsonPropertyName("next_batch")]
     public string NextBatch { get; set; } = null!;
@@ -114,4 +118,4 @@ public class SyncResponse {
             public EventList? InviteState { get; set; }
         }
     }
-}
+}
\ No newline at end of file