diff options
author | Egor Karavaev | 2021-06-07 18:50:20 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2021-06-08 01:02:41 +0000 |
commit | 960bc9f13446e1fbcc36f1a3be3541ec1b9ec5bd (patch) | |
tree | f63b8e528c8bcf6c0efbd3577c14f66ec274fdd6 /helix-lsp/src/client.rs | |
parent | 08f50310bd698aaab1c44b3c2b900648e98bfa5c (diff) |
Don't panic on LSP not starting
Diffstat (limited to 'helix-lsp/src/client.rs')
-rw-r--r-- | helix-lsp/src/client.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/helix-lsp/src/client.rs b/helix-lsp/src/client.rs index a1c1134a..41c38fd9 100644 --- a/helix-lsp/src/client.rs +++ b/helix-lsp/src/client.rs @@ -153,7 +153,7 @@ impl Client { timeout(Duration::from_secs(2), rx.recv()) .await .map_err(|_| Error::Timeout)? // return Timeout - .unwrap() // TODO: None if channel closed + .ok_or(Error::StreamClosed)? } } |