models/issue_mail: don't send email to non-active users (#5788)

Fixes #5782
pull/5793/head
Alexey Agafonov 2019-08-24 10:12:25 +03:00 committed by ᴊ. ᴄʜᴇɴ
parent 2f0cdfd564
commit ddc7a2dd4d
1 changed files with 1 additions and 1 deletions

View File

@ -125,7 +125,7 @@ func mailIssueCommentToParticipants(issue *Issue, doer *User, mentions []string)
if err != nil {
return fmt.Errorf("GetUserByID [%d]: %v", watchers[i].UserID, err)
}
if to.IsOrganization() {
if to.IsOrganization() || !to.IsActive {
continue
}