|
|
|
@ -479,10 +479,7 @@ func SyncPullMirror(ctx context.Context, repoID int64) bool {
|
|
|
|
log.Error("SyncMirrors [repo: %-v]: unable to GetRefCommitID [ref_name: %s]: %v", m.Repo, result.refName, err)
|
|
|
|
log.Error("SyncMirrors [repo: %-v]: unable to GetRefCommitID [ref_name: %s]: %v", m.Repo, result.refName, err)
|
|
|
|
continue
|
|
|
|
continue
|
|
|
|
}
|
|
|
|
}
|
|
|
|
objectFormat, err := git.GetObjectFormatOfRepo(ctx, m.Repo.RepoPath())
|
|
|
|
objectFormat := git.ObjectFormatFromName(m.Repo.ObjectFormatName)
|
|
|
|
if err != nil {
|
|
|
|
|
|
|
|
log.Error("SyncMirrors [repo: %-v]: unable to GetHashTypeOfRepo: %v", m.Repo, err)
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
notify_service.SyncPushCommits(ctx, m.Repo.MustOwner(ctx), m.Repo, &repo_module.PushUpdateOptions{
|
|
|
|
notify_service.SyncPushCommits(ctx, m.Repo.MustOwner(ctx), m.Repo, &repo_module.PushUpdateOptions{
|
|
|
|
RefFullName: result.refName,
|
|
|
|
RefFullName: result.refName,
|
|
|
|
OldCommitID: objectFormat.EmptyObjectID().String(),
|
|
|
|
OldCommitID: objectFormat.EmptyObjectID().String(),
|
|
|
|
|