diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2023-01-04 18:54:54 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-04 18:54:54 -0500 |
commit | 0ee64ad84726f7c91842c6a2dab0cb6a96dead4b (patch) | |
tree | 50d42e65d1f1d1e6b1cffc4e9f38f3e2a5d1dd59 /cli/tools/fmt.rs | |
parent | 319f6074761421b797db71bf10f6171516e3d92a (diff) |
fix: upgrade deno_ast to 0.23 (#17269)
Closes #17172
Closes #15669
Closes #8529
Diffstat (limited to 'cli/tools/fmt.rs')
-rw-r--r-- | cli/tools/fmt.rs | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/cli/tools/fmt.rs b/cli/tools/fmt.rs index 3cfec9019..d146c958e 100644 --- a/cli/tools/fmt.rs +++ b/cli/tools/fmt.rs @@ -327,7 +327,20 @@ async fn check_source_files( not_formatted_files_count.fetch_add(1, Ordering::Relaxed); let _g = output_lock.lock(); warn!("Error checking: {}", file_path.to_string_lossy()); - warn!(" {}", e); + warn!( + "{}", + format!("{}", e) + .split('\n') + .map(|l| { + if l.trim().is_empty() { + String::new() + } else { + format!(" {}", l) + } + }) + .collect::<Vec<_>>() + .join("\n") + ); } } Ok(()) |