Fix compilation errors: duplicate imports, feature-gated functions, type mismatch
Some checks failed
BotServer CI / build (push) Failing after 7m28s

This commit is contained in:
Rodrigo Rodriguez (Pragmatismo) 2026-02-05 18:31:14 -03:00
parent 52bccf0551
commit 35af28a041
3 changed files with 17 additions and 3 deletions

View file

@ -15,7 +15,6 @@ use rcgen::{
BasicConstraints, CertificateParams, DistinguishedName, DnType, IsCa, Issuer, KeyPair,
};
use std::fs;
use std::path::Path;
#[cfg(unix)]
use std::os::unix::fs::PermissionsExt;
use std::path::{Path, PathBuf};

View file

@ -1076,12 +1076,12 @@ Store credentials in Vault:
let db_password = if let Ok(env_pwd) = std::env::var("BOOTSTRAP_DB_PASSWORD") {
env_pwd
} else if !db_password_override.is_empty() {
db_password_override.clone()
db_password_override.to_string()
} else {
match get_database_url_sync() {
Ok(url) => {
let (_, password, _, _, _) = parse_database_url(&url);
password
password.to_string()
}
Err(_) => {
trace!("Vault not available for DB_PASSWORD, using empty string");

View file

@ -134,3 +134,18 @@ pub fn list_embedded_files() -> Vec<String> {
log::debug!("Embedded UI contains {} files", files.len());
files
}
#[cfg(not(feature = "embed-ui"))]
pub fn has_embedded_ui() -> bool {
false
}
#[cfg(not(feature = "embed-ui"))]
pub fn list_embedded_files() -> Vec<String> {
Vec::new()
}
#[cfg(not(feature = "embed-ui"))]
pub fn embedded_ui_router() -> Router {
Router::new()
}