fix: when formatting and add some methods to Project::Error
This commit is contained in:
@@ -24,7 +24,7 @@ pub fn exec(
|
||||
if let Err(err) = aiken_project::format::run(stdin, check, files) {
|
||||
err.report();
|
||||
|
||||
miette::bail!("failed: {} error(s)", err.total());
|
||||
miette::bail!("failed: {} error(s)", err.len());
|
||||
};
|
||||
|
||||
Ok(())
|
||||
|
||||
@@ -30,10 +30,7 @@ where
|
||||
if let Err(err) = build_result {
|
||||
err.report();
|
||||
|
||||
miette::bail!(
|
||||
"failed: {} error(s), {warning_count} warning(s)",
|
||||
err.total(),
|
||||
);
|
||||
miette::bail!("failed: {} error(s), {warning_count} warning(s)", err.len(),);
|
||||
};
|
||||
|
||||
println!("finished with {warning_count} warning(s)");
|
||||
|
||||
Reference in New Issue
Block a user