Check error
Check error
This commit is contained in:
parent
dedfa143ce
commit
2061c32a2e
@ -754,7 +754,11 @@ func removeExistingChain(cctx *cli.Context, lr repo.Repo) error {
|
||||
return xerrors.Errorf("error locking repo: %w", err)
|
||||
}
|
||||
// Ensure that lockedRepo is closed when this function exits
|
||||
defer lockedRepo.Close()
|
||||
defer func() {
|
||||
if closeErr := lockedRepo.Close(); closeErr != nil {
|
||||
log.Errorf("Error closing the lockedRepo: %v", closeErr)
|
||||
}
|
||||
}()
|
||||
|
||||
cfg, err := lockedRepo.Config()
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user