Skip to content

Commit

Permalink
nit: add comment to explain dismissed case
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpatel committed Oct 23, 2024
1 parent 96cae87 commit 3f3be64
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion server/handler/pull_request_review.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,8 @@ func (h *PullRequestReview) Handle(ctx context.Context, eventType, deliveryID st

func (h *PullRequestReview) affectsApproval(reviewState pull.ReviewState, config *policy.Config) bool {
states := make(map[pull.ReviewState]struct{})
// Include dismissed state

// Always process events for dismissed reviews because they can revert the overall approval or disapproval to a previous state
states[pull.ReviewDismissed] = struct{}{}

for _, rule := range config.ApprovalRules {
Expand Down

0 comments on commit 3f3be64

Please sign in to comment.