aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/mozart-registry/src/vcs_bridge.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/mozart-registry/src/vcs_bridge.rs')
-rw-r--r--crates/mozart-registry/src/vcs_bridge.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/crates/mozart-registry/src/vcs_bridge.rs b/crates/mozart-registry/src/vcs_bridge.rs
index 78aaaa5..be61845 100644
--- a/crates/mozart-registry/src/vcs_bridge.rs
+++ b/crates/mozart-registry/src/vcs_bridge.rs
@@ -32,14 +32,20 @@ pub async fn scan_vcs_repositories(repositories: &[RawRepository]) -> Vec<VcsPac
other => Some(other),
};
- let vcs_repo = VcsRepository::new(repo.url.clone(), forced_type, config.clone());
+ // VCS repositories require `url`; skip silently if missing (Composer
+ // would reject this earlier in RepositoryFactory).
+ let Some(url) = repo.url.clone() else {
+ continue;
+ };
+
+ let vcs_repo = VcsRepository::new(url.clone(), forced_type, config.clone());
match vcs_repo.scan().await {
Ok(versions) => {
all_versions.extend(versions);
}
Err(e) => {
- eprintln!("Warning: Failed to scan VCS repository {}: {}", repo.url, e,);
+ eprintln!("Warning: Failed to scan VCS repository {url}: {e}");
}
}
}