diff --git a/crates/workspace/src/workspace.rs b/crates/workspace/src/workspace.rs index 3bc337000fecce97a0212c20b2a359ae3280d158..1452074374a7e51b358dc557f0ee90d00de557a5 100644 --- a/crates/workspace/src/workspace.rs +++ b/crates/workspace/src/workspace.rs @@ -4086,10 +4086,10 @@ pub fn restart(_: &Restart, cx: &mut AppContext) { // If the user cancels any save prompt, then keep the app open. for window in workspace_windows { - if let Some(close) = window.update_root(&mut cx, |workspace, cx| { + if let Some(should_close) = window.update_root(&mut cx, |workspace, cx| { workspace.prepare_to_close(true, cx) }) { - if !close.await? { + if !should_close.await? { return Ok(()); } } diff --git a/crates/zed/src/zed.rs b/crates/zed/src/zed.rs index c62384022804a0a27c6276277eb3a72a24996ca9..1c57174fe289bffe4f0b7e4d245bb017d38f68fc 100644 --- a/crates/zed/src/zed.rs +++ b/crates/zed/src/zed.rs @@ -432,10 +432,10 @@ fn quit(_: &Quit, cx: &mut gpui::AppContext) { // If the user cancels any save prompt, then keep the app open. for window in workspace_windows { - if let Some(close) = window.update_root(&mut cx, |workspace, cx| { - workspace.prepare_to_close(false, cx) + if let Some(should_close) = window.update_root(&mut cx, |workspace, cx| { + workspace.prepare_to_close(true, cx) }) { - if close.await? { + if !should_close.await? { return Ok(()); } }