Просмотр исходного кода

fix mailIssueCommentBatch for pull request (#14252)

fix #14250

Signed-off-by: a101211279 <1012112796@qq.com>
tags/v1.15.0-dev
a1012112796 3 лет назад
Родитель
Сommit
d989247bb0
Аккаунт пользователя с таким Email не найден
1 измененных файлов: 5 добавлений и 1 удалений
  1. 5
    1
      services/mailer/mail_issue.go

+ 5
- 1
services/mailer/mail_issue.go Просмотреть файл

@@ -123,10 +123,14 @@ func mailIssueCommentBatch(ctx *mailCommentContext, ids []int64, visited map[int
return err
}

checkUnit := models.UnitTypeIssues
if ctx.Issue.IsPull {
checkUnit = models.UnitTypePullRequests
}
// Make sure all recipients can still see the issue
idx := 0
for _, r := range recipients {
if ctx.Issue.Repo.CheckUnitUser(r, models.UnitTypeIssues) {
if ctx.Issue.Repo.CheckUnitUser(r, checkUnit) {
recipients[idx] = r
idx++
}

Загрузка…
Отмена
Сохранить