Skip to content

Commit

Permalink
Use []*RequiredStatusCheck instead of []RequiredStatusCheck
Browse files Browse the repository at this point in the history
in RequiredStatusChecksRequest
  • Loading branch information
k24dizzle committed Jan 29, 2022
1 parent 1ee3619 commit d801426
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions github/repos.go
Original file line number Diff line number Diff line change
Expand Up @@ -890,8 +890,8 @@ type RequiredStatusChecksRequest struct {
Strict *bool `json:"strict,omitempty"`
// Note: if both Contexts and Checks are populated,
// the GitHub API will only use Checks.
Contexts []string `json:"contexts,omitempty"`
Checks []RequiredStatusCheck `json:"checks,omitempty"`
Contexts []string `json:"contexts,omitempty"`
Checks []*RequiredStatusCheck `json:"checks,omitempty"`
}

// RequiredStatusCheck represents a status check of a protected branch.
Expand Down
2 changes: 1 addition & 1 deletion github/repos_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1732,7 +1732,7 @@ func TestRepositoriesService_UpdateRequiredStatusChecks_Checks(t *testing.T) {
noAppID := int64(-1)
input := &RequiredStatusChecksRequest{
Strict: Bool(true),
Checks: []RequiredStatusCheck{
Checks: []*RequiredStatusCheck{
{
Context: "continuous-integration",
},
Expand Down

0 comments on commit d801426

Please sign in to comment.