fix(vcs): thread CommitID through abstraction layer (#114) #117

Merged
aweiker merged 2 commits from review-bot-issue-114 into feature/github-support 2026-05-13 23:13:21 +00:00
2 changed files with 3 additions and 1 deletions
Showing only changes of commit 25cb55449e - Show all commits
+1
View File
@@ -108,6 +108,7 @@ func (c *Client) PostReview(ctx context.Context, owner, repo string, number int,
} else if payload.CommitID != comment.CommitID { } else if payload.CommitID != comment.CommitID {
Review

[NIT] The comment // else: matching SHA is a no-op by design is helpful but slightly inconsistent with Go style (comments above the code they describe, not as trailing-else). Minor style point with no functional impact.

**[NIT]** The comment `// else: matching SHA is a no-op by design` is helpful but slightly inconsistent with Go style (comments above the code they describe, not as trailing-else). Minor style point with no functional impact.
return nil, ErrConflictingCommitIDs return nil, ErrConflictingCommitIDs
} }
// else: matching SHA is a no-op by design
} }
payload.Comments = append(payload.Comments, reviewCommentEntry{ payload.Comments = append(payload.Comments, reviewCommentEntry{
Path: comment.Path, Path: comment.Path,
+2 -1
View File
@@ -97,6 +97,7 @@ type ReviewRequest struct {
// CommitID anchors the review to a specific commit SHA. // CommitID anchors the review to a specific commit SHA.
// If empty, the platform defaults to the current PR head. // If empty, the platform defaults to the current PR head.
// Adapters use this as the primary commit anchor for the review submission. // Adapters use this as the primary commit anchor for the review submission.
Review

[NIT] Inconsistent alignment: CommitID string has extra whitespace padding (string json:...) that doesn't match the adjacent Event ReviewEventfield. Likely a gofmt artefact from editing — should be cleaned up sogo vet/gofmt` stays clean.

**[NIT]** Inconsistent alignment: `CommitID string` has extra whitespace padding (`string `json:...`) that doesn't match the adjacent `Event ReviewEvent` field. Likely a gofmt artefact from editing — should be cleaned up so `go vet`/`gofmt` stays clean.
CommitID string `json:"commit_id,omitempty"` CommitID string `json:"commit_id,omitempty"`
Comments []ReviewComment `json:"comments,omitempty"` Comments []ReviewComment `json:"comments,omitempty"`
} }