From 44c94d48dad6c5c0ff727477384653479b4807ed Mon Sep 17 00:00:00 2001 From: dylan Date: Fri, 24 Jan 2025 15:36:39 -0800 Subject: [PATCH] don't include these logs --- rust/feature-flags/src/config.rs | 24 ++++-------------------- 1 file changed, 4 insertions(+), 20 deletions(-) diff --git a/rust/feature-flags/src/config.rs b/rust/feature-flags/src/config.rs index 9ef66117223d3..a57567429945a 100644 --- a/rust/feature-flags/src/config.rs +++ b/rust/feature-flags/src/config.rs @@ -126,33 +126,17 @@ impl Config { } pub fn get_maxmind_db_path(&self) -> PathBuf { - let path = if self.maxmind_db_path.is_empty() { - let manifest_dir = env!("CARGO_MANIFEST_DIR"); - let default_path = Path::new(manifest_dir) + if self.maxmind_db_path.is_empty() { + Path::new(env!("CARGO_MANIFEST_DIR")) .parent() .unwrap() .parent() .unwrap() .join("share") - .join("GeoLite2-City.mmdb"); - - tracing::info!( - "No custom maxmind_db_path set. Using default path: {:?}", - default_path - ); - default_path + .join("GeoLite2-City.mmdb") } else { - let custom_path = PathBuf::from(&self.maxmind_db_path); - tracing::info!("Using custom maxmind_db_path: {:?}", custom_path); - custom_path - }; - - tracing::info!("Checking if path exists: {:?}", path); - if !path.exists() { - tracing::error!("GeoIP database file not found at: {:?}", path); + PathBuf::from(&self.maxmind_db_path) } - - path } }