style: 🎨 apply clippy & rustfmt

This commit is contained in:
daimond113 2024-03-27 00:48:00 +01:00
parent 33aa9dbff9
commit 26da6abd22
No known key found for this signature in database
GPG key ID: 3A8ECE51328B513C
2 changed files with 5 additions and 4 deletions

View file

@ -515,9 +515,8 @@ impl Manifest {
for (specifier, ty) in dependencies { for (specifier, ty) in dependencies {
let overridden = overrides.iter().find_map(|(k_path, spec)| { let overridden = overrides.iter().find_map(|(k_path, spec)| {
(&path == &k_path[..k_path.len() - 1] (path == k_path[..k_path.len() - 1] && k_path.last() == Some(&specifier.name()))
&& k_path.get(k_path.len() - 1) == Some(&specifier.name())) .then_some(spec)
.then_some(spec)
}); });
queue.push_back(( queue.push_back((

View file

@ -298,7 +298,9 @@ impl Project {
if root_deps.contains(&name) { if root_deps.contains(&name) {
let specifier = lockfile.root_specifier(resolved_pkg).unwrap(); let specifier = lockfile.root_specifier(resolved_pkg).unwrap();
let linking_dir = &self.path().join(packages_folder(specifier.realm().copied().unwrap_or_default())); let linking_dir = &self.path().join(packages_folder(
specifier.realm().copied().unwrap_or_default(),
));
debug!( debug!(
"linking root package {name}@{version} to directory {}", "linking root package {name}@{version} to directory {}",