Function ruma_common::serde::deserialize_v1_powerlevel
source · [−]pub fn deserialize_v1_powerlevel<'de, D>(de: D) -> Result<Int, D::Error> where
D: Deserializer<'de>,
Expand description
Take either an integer number or a string and deserialize to an integer number.
To be used like this:
#[serde(deserialize_with = "deserialize_v1_powerlevel")]