Function wicrs_server::api::mute_user [−][src]
pub async fn mute_user(user: &User, hub_id: &ID, user_id: &ID) -> Result<()>
Mutes a user in a hub.
Arguments
user
- User who is muting.hub_id
- Hub in which the user is being muted.user_id
- ID of the user who is to be muted.
Errors
This function may fail for any of the following reasons:
- The user performing the mute is not in the hub
- The hub could not be loaded for any of the reasons outlined by
Hub::load
. - The user performing the mute does not have permission to mute other users.
- The mute failed for any of the reasons outlined by
Hub::mute_user
.