mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-11-23 05:52:10 +00:00
Fix wrong milestone in webhook message (#11596)
Fixes #11295 Signed-off-by: Gary Kim gary@garykim.dev
This commit is contained in:
parent
788b8b1440
commit
5c55793e0e
|
@ -249,7 +249,7 @@ func (issue *Issue) loadReactions(e Engine) (err error) {
|
|||
}
|
||||
|
||||
func (issue *Issue) loadMilestone(e Engine) (err error) {
|
||||
if issue.Milestone == nil && issue.MilestoneID > 0 {
|
||||
if (issue.Milestone == nil || issue.Milestone.ID != issue.MilestoneID) && issue.MilestoneID > 0 {
|
||||
issue.Milestone, err = getMilestoneByRepoID(e, issue.RepoID, issue.MilestoneID)
|
||||
if err != nil && !IsErrMilestoneNotExist(err) {
|
||||
return fmt.Errorf("getMilestoneByRepoID [repo_id: %d, milestone_id: %d]: %v", issue.RepoID, issue.MilestoneID, err)
|
||||
|
|
Loading…
Reference in a new issue