diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2020-10-31 05:59:02 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-30 22:59:02 +0100 |
commit | 4df2ed29f28194513c59733e369152b8f8bc1d36 (patch) | |
tree | 3bb0604e902390f37e2c9a8104f4ccaf495b4291 /services/release | |
parent | dd12384f224e98a130511ebc9ffcfb44ead0e736 (diff) | |
download | gitea-4df2ed29f28194513c59733e369152b8f8bc1d36.tar.gz gitea-4df2ed29f28194513c59733e369152b8f8bc1d36.zip |
Refactor: Move PushUpdateOptions (#13363)
Co-authored-by: Antoine GIRARD <sapk@users.noreply.github.com>
Diffstat (limited to 'services/release')
-rw-r--r-- | services/release/release.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/services/release/release.go b/services/release/release.go index af97987a27..0e04a71898 100644 --- a/services/release/release.go +++ b/services/release/release.go @@ -43,8 +43,12 @@ func createTag(gitRepo *git.Repository, rel *models.Release) error { return err } notification.NotifyPushCommits( - rel.Publisher, rel.Repo, git.TagPrefix+rel.TagName, - git.EmptySHA, commit.ID.String(), repository.NewPushCommits()) + rel.Publisher, rel.Repo, + &repository.PushUpdateOptions{ + RefFullName: git.TagPrefix + rel.TagName, + OldCommitID: git.EmptySHA, + NewCommitID: commit.ID.String(), + }, repository.NewPushCommits()) notification.NotifyCreateRef(rel.Publisher, rel.Repo, "tag", git.TagPrefix+rel.TagName) rel.CreatedUnix = timeutil.TimeStampNow() } |