diff --git a/src/git_ops/git2_ops.rs b/src/git_ops/git2_ops.rs index 23e04eb..3df6c92 100644 --- a/src/git_ops/git2_ops.rs +++ b/src/git_ops/git2_ops.rs @@ -216,13 +216,7 @@ impl GitOperations for Git2Operations { if let Some(submodules) = config.submodules().as_ref() { for (name, entry) in *submodules { // Find or create the submodule - match self.repo.find_submodule( - &entry - .path - .as_ref() - .map(std::string::ToString::to_string) - .unwrap_or(name.clone()), - ) { + match self.repo.find_submodule(entry.path.as_deref().unwrap_or(name)) { Ok(mut submodule) => { // Update existing submodule configuration through git config let mut config = self.repo.config()?;