ui: fix onboarding & allow for key deletion (#1928)

This commit is contained in:
Lily Delalande
2025-03-31 13:00:07 -04:00
committed by GitHub
parent 28cdd0381e
commit 780194798e
11 changed files with 214 additions and 56 deletions
@@ -123,7 +123,14 @@ pub async fn remove_config(
let config = Config::global();
match config.delete(&query.key) {
// Check if the secret flag is true and call the appropriate method
let result = if query.is_secret {
config.delete_secret(&query.key)
} else {
config.delete(&query.key)
};
match result {
Ok(_) => Ok(Json(format!("Removed key {}", query.key))),
Err(_) => Err(StatusCode::NOT_FOUND),
}