Add skip_serializing_if to CreateEventContent

This commit is contained in:
Jonas Platte 2020-05-26 10:04:57 +02:00
parent 38fec0b0a9
commit 512496baeb
No known key found for this signature in database
GPG Key ID: 7D261D771D915378

View File

@ -17,7 +17,11 @@ ruma_event! {
pub creator: UserId, pub creator: UserId,
/// Whether or not this room's data should be transferred to other homeservers. /// Whether or not this room's data should be transferred to other homeservers.
#[serde(rename = "m.federate", default = "ruma_serde::default_true")] #[serde(
rename = "m.federate",
default = "ruma_serde::default_true",
skip_serializing_if = "ruma_serde::is_true"
)]
pub federate: bool, pub federate: bool,
/// The version of the room. Defaults to "1" if the key does not exist. /// The version of the room. Defaults to "1" if the key does not exist.