Skip to content

Commit 97e61e5

Browse files
Norwinnoerwlunny6543
committed
Improve PullReview docs (#469)
document some PullReview fields code review Co-authored-by: Norwin Roosen <[email protected]> Co-authored-by: Lunny Xiao <[email protected]> Co-authored-by: 6543 <[email protected]> Reviewed-on: https://gitea.com/gitea/go-sdk/pulls/469 Reviewed-by: 6543 <[email protected]> Reviewed-by: Lunny Xiao <[email protected]> Co-Authored-By: Norwin <[email protected]> Co-Committed-By: Norwin <[email protected]>
1 parent e34d140 commit 97e61e5

File tree

1 file changed

+11
-9
lines changed

1 file changed

+11
-9
lines changed

gitea/pull_review.go

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,17 @@ const (
3333

3434
// PullReview represents a pull request review
3535
type PullReview struct {
36-
ID int64 `json:"id"`
37-
Reviewer *User `json:"user"`
38-
State ReviewStateType `json:"state"`
39-
Body string `json:"body"`
40-
CommitID string `json:"commit_id"`
41-
Stale bool `json:"stale"`
42-
Official bool `json:"official"`
43-
CodeCommentsCount int `json:"comments_count"`
44-
Submitted time.Time `json:"submitted_at"`
36+
ID int64 `json:"id"`
37+
Reviewer *User `json:"user"`
38+
State ReviewStateType `json:"state"`
39+
Body string `json:"body"`
40+
CommitID string `json:"commit_id"`
41+
// Stale indicates if the pull has changed since the review
42+
Stale bool `json:"stale"`
43+
// Official indicates if the review counts towards the required approval limit, if PR base is a protected branch
44+
Official bool `json:"official"`
45+
CodeCommentsCount int `json:"comments_count"`
46+
Submitted time.Time `json:"submitted_at"`
4547

4648
HTMLURL string `json:"html_url"`
4749
HTMLPullURL string `json:"pull_request_url"`

0 commit comments

Comments
 (0)