Skip to content

Commit 4153e3b

Browse files
committed
fix(ghpr): Also check for state for approvers
Signed-off-by: Cezar Craciunoiu <[email protected]>
1 parent c9a37ad commit 4153e3b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

internal/ghpr/ghpr_mergable.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,10 @@ func (pr *PullRequest) SatisfiesMergeRequirements(ctx context.Context, opts ...P
115115
for _, r := range reviews {
116116
if ok, matches := mopts.requestsApproverRegex(*r.Body); ok {
117117
if mopts.requestsApproverTeam(ctx, *pull, *r.User.Login) {
118+
if !mopts.requestsApproveState(*r.State) {
119+
continue
120+
}
121+
118122
var alreadyApproved bool
119123
for _, approver := range existingApprovers {
120124
if strings.Contains(approver, *r.User.Login) {

0 commit comments

Comments
 (0)