Skip to content

Commit

Permalink
cargo fmt --all
Browse files Browse the repository at this point in the history
  • Loading branch information
emdoyle committed Jan 16, 2025
1 parent 659d300 commit 89dd930
Showing 1 changed file with 22 additions and 24 deletions.
46 changes: 22 additions & 24 deletions src/commands/check_internal/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,31 +83,29 @@ fn process_file(
}
};

project_imports
.active_imports()
.for_each(|import| {
if let Err(error_info) = check_import(
&import.module_path,
module_tree,
Arc::clone(&nearest_module),
&project_config.layers,
project_config.root_module.clone(),
interface_checker,
check_dependencies,
) {
let boundary_error = BoundaryError {
file_path: file_path.clone(),
line_number: import.line_no,
import_mod_path: import.module_path.to_string(),
error_info,
};
if boundary_error.is_deprecated() {
diagnostics.deprecated_warnings.push(boundary_error);
} else {
diagnostics.errors.push(boundary_error);
}
project_imports.active_imports().for_each(|import| {
if let Err(error_info) = check_import(
&import.module_path,
module_tree,
Arc::clone(&nearest_module),
&project_config.layers,
project_config.root_module.clone(),
interface_checker,
check_dependencies,
) {
let boundary_error = BoundaryError {
file_path: file_path.clone(),
line_number: import.line_no,
import_mod_path: import.module_path.to_string(),
error_info,
};
});
if boundary_error.is_deprecated() {
diagnostics.deprecated_warnings.push(boundary_error);
} else {
diagnostics.errors.push(boundary_error);
}
};
});

project_imports
.directive_ignored_imports()
Expand Down

0 comments on commit 89dd930

Please sign in to comment.