diff options
author | zeripath <art27@cantab.net> | 2021-02-08 03:09:14 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-08 11:09:14 +0800 |
commit | 378acc9d966554299e4a7dbe15e6e41026963653 (patch) | |
tree | cfe875029a9c6cb35939fbd0a64ffdc965b2f9b7 /models/issue.go | |
parent | 98827e99f63178c43187e686ffc4bf03d9d18d36 (diff) | |
download | gitea-378acc9d966554299e4a7dbe15e6e41026963653.tar.gz gitea-378acc9d966554299e4a7dbe15e6e41026963653.zip |
Use OldRef instead of CommitSHA for DeleteBranch comments (#14604)
Fix #14545
Signed-off-by: Andrew Thornton <art27@cantab.net>
Co-authored-by: 6543 <6543@obermui.de>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Diffstat (limited to 'models/issue.go')
-rw-r--r-- | models/issue.go | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/models/issue.go b/models/issue.go index a7392633af..b903e82ad7 100644 --- a/models/issue.go +++ b/models/issue.go @@ -745,11 +745,11 @@ func AddDeletePRBranchComment(doer *User, repo *Repository, issueID int64, branc return err } var opts = &CreateCommentOptions{ - Type: CommentTypeDeleteBranch, - Doer: doer, - Repo: repo, - Issue: issue, - CommitSHA: branchName, + Type: CommentTypeDeleteBranch, + Doer: doer, + Repo: repo, + Issue: issue, + OldRef: branchName, } if _, err = createComment(sess, opts); err != nil { return err |