fix: grammer
This commit is contained in:
parent
de65440503
commit
7b276bd38d
@ -65,7 +65,7 @@ pub fn handle_daemon_client(mut stream: UnixStream, config: &Arc<config::Schema>
|
||||
"help" => {
|
||||
_ = writeln!(
|
||||
stream,
|
||||
"avaliable commands:\n help\n configcount\n confdump\n hosts <list|create|delete> ..."
|
||||
"available commands:\n help\n configcount\n confdump\n hosts <list|create|delete> ..."
|
||||
);
|
||||
}
|
||||
"configcount" => {
|
||||
@ -81,7 +81,7 @@ pub fn handle_daemon_client(mut stream: UnixStream, config: &Arc<config::Schema>
|
||||
if let [arg0, args @ ..] = args {
|
||||
match arg0.as_str() {
|
||||
"list" => {
|
||||
_ = writeln!(stream, "aquiring read lock");
|
||||
_ = writeln!(stream, "acquiring read lock");
|
||||
let rlock = config.hosts.read();
|
||||
_ = writeln!(stream, "{rlock:#?}");
|
||||
}
|
||||
@ -94,7 +94,7 @@ pub fn handle_daemon_client(mut stream: UnixStream, config: &Arc<config::Schema>
|
||||
{
|
||||
match value.parse::<net::SocketAddr>() {
|
||||
Ok(addr) => {
|
||||
_ = writeln!(stream, "aquiring write lock");
|
||||
_ = writeln!(stream, "acquiring write lock");
|
||||
let mut wlock = config.hosts.write();
|
||||
wlock.insert(
|
||||
name.to_string(),
|
||||
@ -106,7 +106,7 @@ pub fn handle_daemon_client(mut stream: UnixStream, config: &Arc<config::Schema>
|
||||
Err(err) => {
|
||||
_ = writeln!(
|
||||
stream,
|
||||
"err: parsing value as socket addres {err:?}"
|
||||
"err: parsing value as socket address {err:?}"
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -125,7 +125,7 @@ pub fn handle_daemon_client(mut stream: UnixStream, config: &Arc<config::Schema>
|
||||
}
|
||||
"delete" => {
|
||||
if let [name] = args {
|
||||
_ = writeln!(stream, "aquiring write lock");
|
||||
_ = writeln!(stream, "acquiring write lock");
|
||||
let mut wlock = config.hosts.write();
|
||||
wlock.remove(name);
|
||||
let lock = RwLockWriteGuard::downgrade(wlock);
|
||||
|
@ -42,7 +42,7 @@ fn main() -> anyhow::Result<()> {
|
||||
File::create(args.config)
|
||||
.context("failure creating the config file")?
|
||||
.write_all(constants::DEFAULT_CONFIG)
|
||||
.context("failure writting the contents to the config file")?;
|
||||
.context("failure writing the contents to the config file")?;
|
||||
return Ok(());
|
||||
}
|
||||
|
||||
@ -117,7 +117,7 @@ pub enum ClientError {
|
||||
// auth headers are just added depending on the ID cookie soo, keep a hashmap of IDs and user
|
||||
// data??
|
||||
//
|
||||
// check authethication first of everything as it changes decissions on eveything and give it to fn
|
||||
// check authentication first of everything as it changes decisions on everything and give it to fn
|
||||
// too
|
||||
// fn(req, Option<AuthData>, (adrr, etc)) -> Action
|
||||
//
|
||||
|
Loading…
x
Reference in New Issue
Block a user