Skip to content

Commit

Permalink
fix 500 error when view an issue which's milestone deleted (go-gitea#…
Browse files Browse the repository at this point in the history
  • Loading branch information
lunny committed Aug 13, 2017
1 parent 1709297 commit d9baa1a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/issue.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ func (issue *Issue) loadAttributes(e Engine) (err error) {

if issue.Milestone == nil && issue.MilestoneID > 0 {
issue.Milestone, err = getMilestoneByRepoID(e, issue.RepoID, issue.MilestoneID)
if err != nil {
if err != nil && !IsErrMilestoneNotExist(err) {
return fmt.Errorf("getMilestoneByRepoID [repo_id: %d, milestone_id: %d]: %v", issue.RepoID, issue.MilestoneID, err)
}
}
Expand Down

0 comments on commit d9baa1a

Please sign in to comment.