Skip to content

Commit

Permalink
path rather than uri
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidLee18 committed Oct 30, 2024
1 parent 9ad9b51 commit 37d2042
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ impl LanguageServer for Backend {
self.client
.log_message(MessageType::INFO, "file opened!")
.await;
match read_norminette(&Path::new(p.text_document.uri.as_str())) {
match read_norminette(&Path::new(p.text_document.uri.path())) {
Ok(diags) => {
self.client
.publish_diagnostics(p.text_document.uri, diags, None)
Expand All @@ -67,7 +67,7 @@ impl LanguageServer for Backend {
self.client
.log_message(MessageType::INFO, "file changed!")
.await;
match read_norminette(&Path::new(p.text_document.uri.as_str())) {
match read_norminette(&Path::new(p.text_document.uri.path())) {
Ok(diags) => {
self.client
.publish_diagnostics(p.text_document.uri, diags, None)
Expand All @@ -84,7 +84,7 @@ impl LanguageServer for Backend {
self.client
.log_message(MessageType::INFO, format!("file saved: {:?}", p.text))
.await;
match read_norminette(&Path::new(p.text_document.uri.as_str())) {
match read_norminette(&Path::new(p.text_document.uri.path())) {
Ok(diags) => {
self.client
.publish_diagnostics(p.text_document.uri, diags, None)
Expand Down

0 comments on commit 37d2042

Please sign in to comment.