diff --git a/crates/oxc_language_server/src/linter/error_with_position.rs b/crates/oxc_language_server/src/linter/error_with_position.rs index 369874cd6bfd0..084887c85e052 100644 --- a/crates/oxc_language_server/src/linter/error_with_position.rs +++ b/crates/oxc_language_server/src/linter/error_with_position.rs @@ -1,12 +1,11 @@ - use std::{path::PathBuf, str::FromStr}; use tower_lsp::lsp_types::{ self, CodeDescription, DiagnosticRelatedInformation, NumberOrString, Position, Range, Url, }; -use oxc_diagnostics::{Error, Severity}; use cow_utils::CowUtils; +use oxc_diagnostics::{Error, Severity}; use crate::linter::offset_to_position; @@ -28,7 +27,6 @@ pub struct LabeledSpanWithPosition { pub message: Option, } - #[derive(Debug, Clone)] pub struct DiagnosticReport { pub diagnostic: lsp_types::Diagnostic, @@ -164,4 +162,4 @@ impl ErrorWithPosition { fixed_content: self.fixed_content, } } -} \ No newline at end of file +} diff --git a/crates/oxc_language_server/src/linter/server_linter.rs b/crates/oxc_language_server/src/linter/server_linter.rs index ad78898b02dbf..22104b9768385 100644 --- a/crates/oxc_language_server/src/linter/server_linter.rs +++ b/crates/oxc_language_server/src/linter/server_linter.rs @@ -4,8 +4,8 @@ use tower_lsp::lsp_types::Url; use oxc_linter::{FixKind, Linter}; -use crate::linter::isolated_lint_handler::IsolatedLintHandler; use crate::linter::error_with_position::DiagnosticReport; +use crate::linter::isolated_lint_handler::IsolatedLintHandler; pub struct ServerLinter { linter: Arc, @@ -25,4 +25,4 @@ impl ServerLinter { IsolatedLintHandler::new(Arc::clone(&self.linter)) .run_single(&uri.to_file_path().unwrap(), content) } -} \ No newline at end of file +}