Skip to main content

check_room_member

Function check_room_member 

Source
pub(super) async fn check_room_member<Fetch, Fut, Pdu>(
    room_member_event: &RoomMemberEvent<Pdu>,
    rules: &AuthorizationRules,
    room_create_event: &RoomCreateEvent<Pdu>,
    fetch_state: &Fetch,
) -> Result
where Fetch: Fn(StateEventType, StateKey) -> Fut + Sync, Fut: Future<Output = Result<Pdu>> + Send, Pdu: Event,
Expand description

Check whether the given event passes the m.room.member authorization rules.

This assumes that ruma_signatures::verify_event() was called previously, as some authorization rules depend on the signatures being valid on the event.