Function wicrs_server::api::leave_hub[][src]

pub async fn leave_hub(user: &mut User, hub_id: &ID) -> Result<()>

Removes the given user from a hub.

Arguments

  • user - User to remove from the hub.
  • hub_id - ID of the hub the user is to be removed from.

Errors

  • The user could not be removed from the hub for any of the reasons outlined by User::leave_hub.
  • The hub could not be saved for any of the reasons outlined by Hub::save.