aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/google/go-github/github/authorizations.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/google/go-github/github/authorizations.go')
-rw-r--r--vendor/github.com/google/go-github/github/authorizations.go11
1 files changed, 8 insertions, 3 deletions
diff --git a/vendor/github.com/google/go-github/github/authorizations.go b/vendor/github.com/google/go-github/github/authorizations.go
index 181e83d..638745a 100644
--- a/vendor/github.com/google/go-github/github/authorizations.go
+++ b/vendor/github.com/google/go-github/github/authorizations.go
@@ -63,7 +63,7 @@ type Authorization struct {
App *AuthorizationApp `json:"app,omitempty"`
Note *string `json:"note,omitempty"`
NoteURL *string `json:"note_url,omitempty"`
- UpdateAt *Timestamp `json:"updated_at,omitempty"`
+ UpdatedAt *Timestamp `json:"updated_at,omitempty"`
CreatedAt *Timestamp `json:"created_at,omitempty"`
Fingerprint *string `json:"fingerprint,omitempty"`
@@ -343,8 +343,13 @@ func (s *AuthorizationsService) Revoke(ctx context.Context, clientID string, tok
// tokens an application has generated for the user.
//
// GitHub API docs: https://developer.github.com/v3/oauth_authorizations/#list-your-grants
-func (s *AuthorizationsService) ListGrants(ctx context.Context) ([]*Grant, *Response, error) {
- req, err := s.client.NewRequest("GET", "applications/grants", nil)
+func (s *AuthorizationsService) ListGrants(ctx context.Context, opt *ListOptions) ([]*Grant, *Response, error) {
+ u, err := addOptions("applications/grants", opt)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ req, err := s.client.NewRequest("GET", u, nil)
if err != nil {
return nil, nil, err
}