Send worktree updates after project metadata has been sent

This commit is contained in:
Antonio Scandurra 2022-11-16 14:58:11 +01:00
parent eeb32fa888
commit 117458f4f6
3 changed files with 56 additions and 27 deletions

View file

@ -1531,7 +1531,8 @@ impl Workspace {
RemoveWorktreeFromProject(worktree_id): &RemoveWorktreeFromProject,
cx: &mut ViewContext<Self>,
) {
self.project
let _ = self
.project
.update(cx, |project, cx| project.remove_worktree(*worktree_id, cx));
}
@ -3177,7 +3178,7 @@ mod tests {
// Remove a project folder
project.update(cx, |project, cx| {
project.remove_worktree(worktree_id, cx);
let _ = project.remove_worktree(worktree_id, cx);
});
assert_eq!(
cx.current_window_title(window_id).as_deref(),