Skip to content

Commit 7e08693

Browse files
committed
kepval: Fix PRR approver search
Signed-off-by: Stephen Augustus <[email protected]>
1 parent 97646d0 commit 7e08693

File tree

1 file changed

+2
-13
lines changed

1 file changed

+2
-13
lines changed

pkg/kepval/approval.go

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -70,18 +70,7 @@ func ValidatePRR(kep *api.Proposal, h *api.PRRHandler, prrDir string) error {
7070
return errors.Wrapf(prr.Error, "%v has an error", prrFilepath)
7171
}
7272

73-
// TODO: Check for edge cases
74-
var stageMilestone string
75-
switch kep.Stage {
76-
case "alpha":
77-
stageMilestone = kep.Milestone.Alpha
78-
case "beta":
79-
stageMilestone = kep.Milestone.Beta
80-
case "stable":
81-
stageMilestone = kep.Milestone.Stable
82-
}
83-
84-
stagePRRApprover := prr.ApproverForStage(stageMilestone)
73+
stagePRRApprover := prr.ApproverForStage(kep.Stage)
8574
validApprover := api.IsOneOf(stagePRRApprover, h.PRRApprovers)
8675
if !validApprover {
8776
return errors.New(
@@ -97,7 +86,7 @@ func ValidatePRR(kep *api.Proposal, h *api.PRRHandler, prrDir string) error {
9786
}
9887

9988
func isPRRRequired(kep *api.Proposal) (required, missingMilestone bool, err error) {
100-
logrus.Infof("checking if PRR is required")
89+
logrus.Debug("checking if PRR is required")
10190

10291
required = true
10392
missingMilestone = kep.IsMissingMilestone()

0 commit comments

Comments
 (0)