-
Notifications
You must be signed in to change notification settings - Fork 10
Update comment even if all approved #55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -294,7 +294,7 @@ func (a *App) processApprovalsAndReviewers() (bool, string, []string, error) { | |
| func (a *App) addReviewStatusComment(allRequiredOwners codeowners.ReviewerGroups, maxReviewsMet bool) error { | ||
| // Comment on the PR with the codeowner teams required for review | ||
|
|
||
| if a.config.Quiet || len(allRequiredOwners) == 0 { | ||
| if a.config.Quiet { | ||
| a.printDebug("Skipping review status comment (disabled or no unapproved owners).\n") | ||
| return nil | ||
| } | ||
|
Comment on lines
+297
to
300
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The removal of the |
||
|
|
@@ -334,7 +334,7 @@ func (a *App) addReviewStatusComment(allRequiredOwners codeowners.ReviewerGroups | |
| if err != nil { | ||
| return fmt.Errorf("UpdateComment Error: %v", err) | ||
| } | ||
| } else { | ||
| } else if len(allRequiredOwners) > 0 { | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The condition |
||
| a.printDebug("Adding new review status comment: %q\n", comment) | ||
| err = a.client.AddComment(comment) | ||
| if err != nil { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The log message is now misleading after the logic change. The function no longer skips if there are no unapproved owners. The message should be updated to reflect that it only skips when
quietmode is enabled.