Skip to content

Commit

Permalink
Remove everest custom preview header (google#1391)
Browse files Browse the repository at this point in the history
  • Loading branch information
vikkyomkar authored and gmlewis committed Jan 27, 2020
1 parent d14f9fb commit 8e32804
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 7 deletions.
3 changes: 0 additions & 3 deletions github/github.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,6 @@ const (

// https://developer.github.com/changes/2019-10-03-multi-line-comments/
mediaTypeMultiLineCommentsPreview = "application/vnd.github.comfort-fade-preview+json"

// https://developer.github.com/v3/repos/#create-a-repository-dispatch-event
mediaTypeRepositoryDispatchPreview = "application/vnd.github.everest-preview+json"
)

// A Client manages communication with the GitHub API.
Expand Down
3 changes: 0 additions & 3 deletions github/repos.go
Original file line number Diff line number Diff line change
Expand Up @@ -1473,9 +1473,6 @@ func (s *RepositoriesService) Dispatch(ctx context.Context, owner, repo string,
return nil, nil, err
}

// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeRepositoryDispatchPreview)

r := new(Repository)
resp, err := s.client.Do(ctx, req, r)
if err != nil {
Expand Down
1 change: 0 additions & 1 deletion github/repos_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1808,7 +1808,6 @@ func TestRepositoriesService_Dispatch(t *testing.T) {
json.NewDecoder(r.Body).Decode(&v)

testMethod(t, r, "POST")
testHeader(t, r, "Accept", mediaTypeRepositoryDispatchPreview)
if !reflect.DeepEqual(v, input) {
t.Errorf("Request body = %+v, want %+v", v, input)
}
Expand Down

0 comments on commit 8e32804

Please sign in to comment.