mirror of
https://github.com/spacebarchat/server.git
synced 2026-10-23 15:13:05 +00:00
Include presence for member object
This commit is contained in:
1 parent
1a9139eef8
commit
81292a4711
1 file changed
+6
@@ -175,6 +175,12 @@ public class MemberJsonConverter : JsonConverter<Member>
|
||||
writer.WritePropertyName("roles");
|
||||
JsonSerializer.Serialize(writer, value.Roles);
|
||||
}
|
||||
|
||||
if (value is MemberWithPresence mwp && mwp.Presence != null)
|
||||
{
|
||||
writer.WritePropertyName("presence");
|
||||
JsonSerializer.Serialize(writer, mwp.Presence);
|
||||
}
|
||||
}
|
||||
writer.WriteEndObject();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user