if err = SyncReleasesWithTags(repo, gitRepo); err != nil {
log.Error(4, "Failed to synchronize tags to releases for repository: %v", err)
}
- UpdateRepoIndexer(repo)
}
if err = repo.UpdateSize(); err != nil {
}
repo.IsMirror = true
- return repo, UpdateRepository(repo, false)
+ err = UpdateRepository(repo, false)
+ } else {
+ repo, err = CleanUpMigrateInfo(repo)
+ }
+
+ if err != nil && !repo.IsBare {
+ UpdateRepoIndexer(repo)
}
- return CleanUpMigrateInfo(repo)
+ return repo, err
}
// cleanUpMigrateGitConfig removes mirror info which prevents "push --all".