fix: hook post-receive for sha256 repos

This commit is contained in:
oliverpool 2024-05-15 15:42:29 +02:00
commit 5e73c67d67
8 changed files with 50 additions and 22 deletions

View file

@ -515,8 +515,7 @@ func (*actionsNotifier) MergePullRequest(ctx context.Context, doer *user_model.U
}
func (n *actionsNotifier) PushCommits(ctx context.Context, pusher *user_model.User, repo *repo_model.Repository, opts *repository.PushUpdateOptions, commits *repository.PushCommits) {
commitID, _ := git.NewIDFromString(opts.NewCommitID)
if commitID.IsZero() {
if git.IsEmptyCommitID(opts.NewCommitID, nil) {
log.Trace("new commitID is empty")
return
}