Skip to main content

can

Function can 

Source
pub fn can(power_levels: &Value, action: PowerAction, mxid: &str) -> bool
Expand description

Whether mxid’s user_level reaches the threshold action names (falling back to the Matrix default when the corresponding field is missing — see PowerAction::field_and_default).