pub fn deserialize_raw_object<'de, T, D>(
deserializer: D,
) -> Result<Raw<T>, D::Error>where
D: Deserializer<'de>,Expand description
Deserialize a Raw<T> and reject any value whose top-level JSON shape is not an object.
Use as #[serde(deserialize_with = "ruma_common::serde::deserialize_raw_object")] wherever
the Matrix spec mandates an object (e.g., Raw<EventContent> on the body of
/_matrix/client/.../send endpoints, or on inner fields, response fields, etc.).