Skip to content

Commit

Permalink
Fix clippy lint
Browse files Browse the repository at this point in the history
  • Loading branch information
hecrj committed Mar 22, 2024
1 parent 4114b04 commit f78ddf1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/compiler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ impl Compiler {

let gitignore = root.as_ref().join(".gitignore");
if let Ok(mut ignored) = fs::read_to_string(&gitignore) {
if !ignored.ends_with("\n") {
ignored.push_str("\n");
if !ignored.ends_with('\n') {
ignored.push('\n');
}

if !ignored.lines().any(|line| line == "target") {
Expand Down

0 comments on commit f78ddf1

Please sign in to comment.