1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-20 05:39:42 +02:00

Moved from Dep to Go Modules

We have finally dropped go dep and moved over to go mod !

During the move, some dependencies have been bumped.
This commit is contained in:
HarveyKandola 2019-09-06 11:06:28 +01:00
parent 2c164a135a
commit b826852137
164 changed files with 18268 additions and 10658 deletions

View file

@ -21,6 +21,7 @@ type OrganizationsService service
type Organization struct {
Login *string `json:"login,omitempty"`
ID *int64 `json:"id,omitempty"`
NodeID *string `json:"node_id,omitempty"`
AvatarURL *string `json:"avatar_url,omitempty"`
HTMLURL *string `json:"html_url,omitempty"`
Name *string `json:"name,omitempty"`
@ -43,7 +44,6 @@ type Organization struct {
BillingEmail *string `json:"billing_email,omitempty"`
Type *string `json:"type,omitempty"`
Plan *Plan `json:"plan,omitempty"`
NodeID *string `json:"node_id,omitempty"`
// API URLs
URL *string `json:"url,omitempty"`
@ -75,8 +75,11 @@ func (p Plan) String() string {
// OrganizationsService.ListAll method.
type OrganizationsListOptions struct {
// Since filters Organizations by ID.
Since int `url:"since,omitempty"`
Since int64 `url:"since,omitempty"`
// Note: Pagination is powered exclusively by the Since parameter,
// ListOptions.Page has no effect.
// ListOptions.PerPage controls an undocumented GitHub API parameter.
ListOptions
}
@ -98,9 +101,6 @@ func (s *OrganizationsService) ListAll(ctx context.Context, opt *OrganizationsLi
return nil, nil, err
}
// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeGraphQLNodeIDPreview)
orgs := []*Organization{}
resp, err := s.client.Do(ctx, req, &orgs)
if err != nil {
@ -130,9 +130,6 @@ func (s *OrganizationsService) List(ctx context.Context, user string, opt *ListO
return nil, nil, err
}
// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeGraphQLNodeIDPreview)
var orgs []*Organization
resp, err := s.client.Do(ctx, req, &orgs)
if err != nil {
@ -152,9 +149,6 @@ func (s *OrganizationsService) Get(ctx context.Context, org string) (*Organizati
return nil, nil, err
}
// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeGraphQLNodeIDPreview)
organization := new(Organization)
resp, err := s.client.Do(ctx, req, organization)
if err != nil {
@ -174,9 +168,6 @@ func (s *OrganizationsService) GetByID(ctx context.Context, id int64) (*Organiza
return nil, nil, err
}
// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeGraphQLNodeIDPreview)
organization := new(Organization)
resp, err := s.client.Do(ctx, req, organization)
if err != nil {
@ -196,9 +187,6 @@ func (s *OrganizationsService) Edit(ctx context.Context, name string, org *Organ
return nil, nil, err
}
// TODO: remove custom Accept header when this API fully launches.
req.Header.Set("Accept", mediaTypeGraphQLNodeIDPreview)
o := new(Organization)
resp, err := s.client.Do(ctx, req, o)
if err != nil {