Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Restore temp file initialization in telemetry code
Mikayla1d7dc96135fc
diff --git a/crates/client/src/telemetry.rs b/crates/client/src/telemetry.rsindex aa0c7c4af58..ee001614400 100644--- a/crates/client/src/telemetry.rs+++ b/crates/client/src/telemetry.rs@@ -14,6 +14,7 @@ use sysinfo::{};use tempfile::NamedTempFile;use util::http::HttpClient;+use util::ResultExt;use util::{channel::ReleaseChannel, TryFutureExt};use self::event_coalescer::EventCoalescer;@@ -167,6 +168,19 @@ impl Telemetry {event_coalescer: EventCoalescer::new(),}));+ cx.background_executor()+ .spawn({+ let state = state.clone();+ async move {+ if let Some(tempfile) =+ NamedTempFile::new_in(util::paths::CONFIG_DIR.as_path()).log_err()+ {+ state.lock().log_file = Some(tempfile);+ }+ }+ })+ .detach();+cx.observe_global::<SettingsStore>({let state = state.clone();