From 74915776c6ddc2d84f028cc505c6cb7770ae8f95 Mon Sep 17 00:00:00 2001 From: Pascal Kuthe Date: Fri, 8 Dec 2023 21:35:26 +0100 Subject: [PATCH] fix typos Co-authored-by: Michael Davis --- helix-lsp/src/file_operations.rs | 2 +- helix-view/src/document.rs | 2 +- helix-view/src/editor.rs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/helix-lsp/src/file_operations.rs b/helix-lsp/src/file_operations.rs index d661db5ec9fe1..50404696465bc 100644 --- a/helix-lsp/src/file_operations.rs +++ b/helix-lsp/src/file_operations.rs @@ -94,7 +94,7 @@ impl FileOperationsInterest { .workspace .as_ref() .and_then(|capabilities| capabilities.file_operations.as_ref()); - let Some(capabilities) =capabilities else { + let Some(capabilities) = capabilities else { return FileOperationsInterest::default(); }; FileOperationsInterest { diff --git a/helix-view/src/document.rs b/helix-view/src/document.rs index 4f5cc1a376fb4..c43886570b584 100644 --- a/helix-view/src/document.rs +++ b/helix-view/src/document.rs @@ -1046,7 +1046,7 @@ impl Document { self.encoding } - /// sets the document path withoult sending events to various + /// sets the document path without sending events to various /// observers (like LSP), in most cases `Editor::set_doc_path` /// should be used instead pub fn set_path(&mut self, path: Option<&Path>) { diff --git a/helix-view/src/editor.rs b/helix-view/src/editor.rs index 573f372a7b651..62b00fa4047d4 100644 --- a/helix-view/src/editor.rs +++ b/helix-view/src/editor.rs @@ -1189,7 +1189,7 @@ impl Editor { self.launch_language_servers(doc_id) } - /// moves/renames a path, invocing any event handlers (currently only lsp) + /// moves/renames a path, invoking any event handlers (currently only lsp) /// and calling `set_doc_path` if the file is open in the editor pub fn move_path(&mut self, old_path: &Path, new_path: &Path) -> io::Result<()> { let new_path = get_canonicalized_path(new_path); @@ -1256,7 +1256,7 @@ impl Editor { // we need to clear the list of language servers here so that // refresh_doc_language/refresh_language_servers doesn't resend // text_document_did_close. Since we called `text_document_did_close` - // we have fully unregistered this document form its LS + // we have fully unregistered this document from its LS doc.language_servers.clear(); doc.set_path(Some(path)); self.refresh_language_servers(doc_id)