usecrate::core::Ctx;useanyhow::Result;pub(crate)fnremove(ctx:&mut Ctx, name: String)->Result<()>{ifletSome(c)= ctx.cluster.as_mut(){if!c.members.contains_key(&name){println!("Couldn't find member with name '{}'", name);returnOk(());}
c.members.remove(&name);println!("Removed '{}' from cluster", name);}else{println!("There is no cluster set up!");}Ok(())}