Skip to content

Commit

Permalink
Resolve PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
heaths committed May 9, 2022
1 parent fc2567a commit 291776a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions internal/api/http.go
Expand Up @@ -149,9 +149,9 @@ func handleHTTPError(resp *http.Response) error {
var errString string
_ = json.Unmarshal(raw, &errString)
messages = append(messages, errString)
httpError.Errors = append(httpError.Errors, api.HttpErrorItem{Message: errString})
httpError.Errors = append(httpError.Errors, api.HTTPErrorItem{Message: errString})
case '{':
var errInfo api.HttpErrorItem
var errInfo api.HTTPErrorItem
_ = json.Unmarshal(raw, &errInfo)
msg := errInfo.Message
if errInfo.Code != "" && errInfo.Code != "custom" {
Expand Down
2 changes: 1 addition & 1 deletion pkg/api/client.go
Expand Up @@ -100,7 +100,7 @@ type GQLClient interface {
Query(name string, query interface{}, variables map[string]interface{}) error
}

// GQLError contains GQLErrors from a GraphQ request.
// GQLError contains GQLErrors from a GraphQL request.
type GQLError struct {
Errors []GQLErrorItem
}
Expand Down
4 changes: 2 additions & 2 deletions pkg/api/http.go
Expand Up @@ -12,12 +12,12 @@ type HTTPError struct {
RequestURL *url.URL
Message string
OAuthScopes string
Errors []HttpErrorItem
Errors []HTTPErrorItem
}

// HTTPErrorItem stores additional information about an error response
// returned from the GitHub API.
type HttpErrorItem struct {
type HTTPErrorItem struct {
Message string
Resource string
Field string
Expand Down

0 comments on commit 291776a

Please sign in to comment.