Skip to content

Commit

Permalink
clippy fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
liuchengxu committed Dec 28, 2024
1 parent ad5fc0d commit ed45fe4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions crates/maple_core/src/stdio_server/provider/hooks/on_move.rs
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ impl<'a> CachedPreviewImpl<'a> {
column_range: Option<Range<usize>>,
container_width: usize,
) -> Preview {
tracing::debug!(path = %path.display(), "Previewing file at line {lnum}");
tracing::debug!("Previewing file {}:{lnum}", path.display());

match detect_file_class(path) {
Ok(FileClass::NotRegularFile) => {
Expand Down Expand Up @@ -766,7 +766,7 @@ fn detect_file_class(path: &Path) -> std::io::Result<FileClass> {
return Ok(FileClass::NotRegularFile);
}

let mut file = std::fs::File::open(&path)?;
let mut file = std::fs::File::open(path)?;
let metadata = file.metadata()?;

let mut buf = vec![0u8; 1024];
Expand Down

0 comments on commit ed45fe4

Please sign in to comment.