This commit is contained in:
Lunny Xiao 2024-04-26 21:12:17 +09:00 committed by GitHub
commit 08375feffe
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 8 deletions

View File

@ -467,14 +467,6 @@ func (pr *PullRequest) SetMerged(ctx context.Context) (bool, error) {
pr.HasMerged = true
sess := db.GetEngine(ctx)
if _, err := sess.Exec("UPDATE `issue` SET `repo_id` = `repo_id` WHERE `id` = ?", pr.IssueID); err != nil {
return false, err
}
if _, err := sess.Exec("UPDATE `pull_request` SET `issue_id` = `issue_id` WHERE `id` = ?", pr.ID); err != nil {
return false, err
}
pr.Issue = nil
if err := pr.LoadIssue(ctx); err != nil {
return false, err