Browse Source

use *[]string for DeploymentRequest.RequiredContexts

There's no way of serializing/requesting an empty required_contexts that
is needed for bypassing the commit status checks for the ref.

It's a breaking change but will allow to serialize an empty array and
omit empty value as expected.
Victor Castell 11 years ago
parent
commit
b2f8d2ec40
1 changed files with 7 additions and 7 deletions
  1. +7
    -7
      github/repos_deployments.go

+ 7
- 7
github/repos_deployments.go View File

@ -27,13 +27,13 @@ type Deployment struct {
// DeploymentRequest represents a deployment request
type DeploymentRequest struct {
Ref *string `json:"ref,omitempty"`
Task *string `json:"task,omitempty"`
AutoMerge *bool `json:"auto_merge,omitempty"`
RequiredContexts []string `json:"required_contexts,omitempty"`
Payload *string `json:"payload,omitempty"`
Environment *string `json:"environment,omitempty"`
Description *string `json:"description,omitempty"`
Ref *string `json:"ref,omitempty"`
Task *string `json:"task,omitempty"`
AutoMerge *bool `json:"auto_merge,omitempty"`
RequiredContexts *[]string `json:"required_contexts,omitempty"`
Payload *string `json:"payload,omitempty"`
Environment *string `json:"environment,omitempty"`
Description *string `json:"description,omitempty"`
}
// DeploymentsListOptions specifies the optional parameters to the


Loading…
Cancel
Save