Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Fix some more warnings
Piotr Osiewicz8ca9f4e12a6a
diff --git a/crates/call2/src/call2.rs b/crates/call2/src/call2.rsindex 534964b3c27..9a89ec7167f 100644--- a/crates/call2/src/call2.rs+++ b/crates/call2/src/call2.rs@@ -3,7 +3,7 @@ pub mod participant;pub mod room;mod shared_screen;-use anyhow::{anyhow, bail, Result};+use anyhow::{anyhow, Result};use async_trait::async_trait;use audio::Audio;use call_settings::CallSettings;@@ -14,8 +14,8 @@ use client::{use collections::HashSet;use futures::{channel::oneshot, future::Shared, Future, FutureExt};use gpui::{- AppContext, AsyncAppContext, AsyncWindowContext, Context, EventEmitter, Model, ModelContext,- Subscription, Task, View, ViewContext, VisualContext, WeakModel, WeakView,+ AppContext, AsyncAppContext, Context, EventEmitter, Model, ModelContext, Subscription, Task,+ View, ViewContext, VisualContext, WeakModel, WeakView,};pub use participant::ParticipantLocation;use postage::watch;@@ -609,7 +609,7 @@ impl CallHandler for Call {fn room_id(&self, cx: &AppContext) -> Option<u64> {Some(self.active_call.as_ref()?.0.read(cx).room()?.read(cx).id())}- fn hang_up(&self, mut cx: &mut AppContext) -> Task<Result<()>> {+ fn hang_up(&self, cx: &mut AppContext) -> Task<Result<()>> {let Some((call, _)) = self.active_call.as_ref() else {return Task::ready(Err(anyhow!("Cannot exit a call; not in a call")));};diff --git a/crates/collab_ui2/src/collab_titlebar_item.rs b/crates/collab_ui2/src/collab_titlebar_item.rsindex bfa2932aee2..b5ed8b09199 100644--- a/crates/collab_ui2/src/collab_titlebar_item.rs+++ b/crates/collab_ui2/src/collab_titlebar_item.rs@@ -233,9 +233,11 @@ impl Render for CollabTitlebarItem {.child(IconButton::new("leave-call", ui::Icon::Exit).on_click({let workspace = workspace.clone();move |_, cx| {- workspace.update(cx, |this, cx| {- this.call_state().hang_up(cx).detach();- });+ workspace+ .update(cx, |this, cx| {+ this.call_state().hang_up(cx).detach();+ })+ .log_err();}})),)diff --git a/crates/collab_ui2/src/face_pile.rs b/crates/collab_ui2/src/face_pile.rsindex 61a2ef85b5b..e235f33ce61 100644--- a/crates/collab_ui2/src/face_pile.rs+++ b/crates/collab_ui2/src/face_pile.rs@@ -1,8 +1,6 @@use gpui::{- div, AnyElement, Div, IntoElement as _, ParentElement as _, Render, RenderOnce, Styled,- ViewContext, WindowContext,+ div, AnyElement, Div, IntoElement as _, ParentElement as _, RenderOnce, Styled, WindowContext,};-use ui::Avatar;#[derive(Default)]pub(crate) struct FacePile {