fix: avoid register logger when enable tracing feature

This commit is contained in:
Tunglies
2026-02-05 17:15:05 +08:00
parent c3f7ff7aa2
commit 781313e8f0
3 changed files with 2 additions and 1 deletions
+1
View File
@@ -68,6 +68,7 @@ impl Logger {
self.log_max_size.store(log_max_size, Ordering::SeqCst);
self.log_max_count.store(log_max_count, Ordering::SeqCst);
#[cfg(not(feature = "tokio-trace"))]
#[cfg(not(feature = "tauri-dev"))]
{
let log_spec = Self::generate_log_spec(log_level);
+1
View File
@@ -33,6 +33,7 @@ pub fn init_work_dir_and_logger() -> anyhow::Result<()> {
init_work_config().await;
init_resources().await;
logging!(info, Type::Setup, "Initializing logger");
// #[cfg(not(feature = "tokio-trace"))]
Logger::global().init().await?;
Ok(())
})