dmitri.shuralyov.com/service/change/...

Add initial support for changes requested event.
dmitshur committed 2 years ago commit 3187272212e5690d0d77d8b55234f19eb4f8ff6e
githubapi/githubapi.go
@@ -498,10 +498,13 @@ func (s service) ListTimeline(ctx context.Context, rs string, id uint64, opt *ch
 		case "PullRequestReview":
 			switch event.PullRequestReview.State {
 			case githubql.PullRequestReviewStateApproved:
 				// TODO: Make this a thing that ListComments returns, etc. After all, it can have a non-empty body.
 				e.Payload = changes.ApprovedEvent{}
+			case githubql.PullRequestReviewStateChangesRequested:
+				// TODO: Make this a thing that ListComments returns, etc. After all, it can have a non-empty body.
+				e.Payload = changes.ChangesRequestedEvent{}
 			default:
 				continue
 			}
 			e.Actor = ghActor(event.PullRequestReview.Author)
 			e.CreatedAt = event.PullRequestReview.CreatedAt.Time
timeline.go
@@ -76,7 +76,8 @@ type (
 		CommitHTMLURL string // Optional.
 		RefName       string
 	}
 
 	// TODO: Merge into Comment or so.
-	ApprovedEvent struct{}
+	ApprovedEvent         struct{}
+	ChangesRequestedEvent struct{}
 )