Skip to content

Commit 1cec7f5

Browse files
authored
Fix bug on detect issue/comment writer (#17592)
1 parent 1cb1101 commit 1cec7f5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

routers/web/repo/issue.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1019,7 +1019,7 @@ func commentTag(repo *models.Repository, poster *models.User, issue *models.Issu
10191019
return models.CommentTagNone, err
10201020
}
10211021

1022-
if perm.CanWrite(models.UnitTypeCode) {
1022+
if perm.CanWriteIssuesOrPulls(issue.IsPull) {
10231023
return models.CommentTagWriter, nil
10241024
}
10251025

0 commit comments

Comments
 (0)