diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2022-04-01 14:05:31 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-01 14:05:31 +0800 |
commit | 89b9d42f083b1f83ee8fc3ba0feaaa7cf04ec05b (patch) | |
tree | e5ab9cdf543d84b89324a4c70e27d1494232d185 /models/review.go | |
parent | 124b072f0b69650baff086b9688d198f5a6761af (diff) | |
download | gitea-89b9d42f083b1f83ee8fc3ba0feaaa7cf04ec05b.tar.gz gitea-89b9d42f083b1f83ee8fc3ba0feaaa7cf04ec05b.zip |
Fix broken of team create (#19288)
* Fix broken of team create
* Update models/organization/team.go
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Diffstat (limited to 'models/review.go')
-rw-r--r-- | models/review.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/models/review.go b/models/review.go index 6ef8d530b6..f360d459cf 100644 --- a/models/review.go +++ b/models/review.go @@ -273,7 +273,7 @@ func isOfficialReviewerTeam(ctx context.Context, issue *Issue, team *organizatio } if !pr.ProtectedBranch.EnableApprovalsWhitelist { - return team.UnitAccessMode(ctx, unit.TypeCode) >= perm.AccessModeWrite, nil + return team.UnitAccessModeCtx(ctx, unit.TypeCode) >= perm.AccessModeWrite, nil } return base.Int64sContains(pr.ProtectedBranch.ApprovalsWhitelistTeamIDs, team.ID), nil |