Add telemetry::event! (#22146)

CC @JosephTLyons

Release Notes:

- N/A
This commit is contained in:
Conrad Irwin 2024-12-17 11:39:18 -07:00 committed by GitHub
parent b17f2089a2
commit 7425d242bc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
24 changed files with 179 additions and 140 deletions

View file

@ -733,7 +733,7 @@ impl Item for Editor {
project: Model<Project>,
cx: &mut ViewContext<Self>,
) -> Task<Result<()>> {
self.report_editor_event("save", None, cx);
self.report_editor_event("Editor Saved", None, cx);
let buffers = self.buffer().clone().read(cx).all_buffers();
let buffers = buffers
.into_iter()
@ -805,7 +805,7 @@ impl Item for Editor {
.path
.extension()
.map(|a| a.to_string_lossy().to_string());
self.report_editor_event("save", file_extension, cx);
self.report_editor_event("Editor Saved", file_extension, cx);
project.update(cx, |project, cx| project.save_buffer_as(buffer, path, cx))
}