Do not panic when finding unmanaged worktrees fails

This commit is contained in:
2022-05-26 16:19:10 +02:00
parent 50a0f4d766
commit 35e7c34d11

View File

@@ -132,7 +132,7 @@ pub fn get_worktree_status_table(
)); ));
} }
} }
for worktree in Repo::find_unmanaged_worktrees(repo, directory).unwrap() { for worktree in Repo::find_unmanaged_worktrees(repo, directory)? {
errors.push(format!( errors.push(format!(
"Found {}, which is not a valid worktree directory!", "Found {}, which is not a valid worktree directory!",
&worktree &worktree