fix compilation warnings #959

Merged
lx merged 5 commits from fixes into main 2025-02-14 17:32:31 +00:00
Showing only changes of commit 2729a71d9d - Show all commits

View file

@ -13,7 +13,6 @@ static GARAGE_TEST_SECRET: &str =
#[derive(Debug, Default, Clone)] #[derive(Debug, Default, Clone)]
pub struct Key { pub struct Key {
pub name: Option<String>,
pub id: String, pub id: String,
pub secret: String, pub secret: String,
} }
@ -213,10 +212,7 @@ api_bind_addr = "127.0.0.1:{admin_port}"
assert!(!key.id.is_empty(), "Invalid key: Key ID is empty"); assert!(!key.id.is_empty(), "Invalid key: Key ID is empty");
assert!(!key.secret.is_empty(), "Invalid key: Key secret is empty"); assert!(!key.secret.is_empty(), "Invalid key: Key secret is empty");
Key { key
name: maybe_name.map(String::from),
..key
}
} }
} }