diff options
author | Yomain | 2023-07-11 17:51:04 +0000 |
---|---|---|
committer | GitHub | 2023-07-11 17:51:04 +0000 |
commit | 8afc0282f28e73cf78d1bd7b11d78fd853ae2036 (patch) | |
tree | 6742e141f051d352ebe7017f15805613670864b9 /helix-lsp/src | |
parent | 1adb19464f002926e1042027b41acef4c81585f6 (diff) |
Fix crash when cwd is deleted (#7185)
Diffstat (limited to 'helix-lsp/src')
-rw-r--r-- | helix-lsp/src/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-lsp/src/lib.rs b/helix-lsp/src/lib.rs index 277a4c28..95c61086 100644 --- a/helix-lsp/src/lib.rs +++ b/helix-lsp/src/lib.rs @@ -931,7 +931,7 @@ pub fn find_lsp_workspace( let mut file = if file.is_absolute() { file.to_path_buf() } else { - let current_dir = std::env::current_dir().expect("unable to determine current directory"); + let current_dir = helix_loader::current_working_dir(); current_dir.join(file) }; file = path::get_normalized_path(&file); |