Skip to content

Commit

Permalink
fixing golint feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisPates committed Aug 28, 2024
1 parent 84d9023 commit 96c34b0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
7 changes: 4 additions & 3 deletions internal/aws/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,15 @@ import (
)

var (
// User not found error
// ErrUserNotFound

Check failure on line 31 in internal/aws/client.go

View workflow job for this annotation

GitHub Actions / test

comment on exported var ErrUserNotFound should be of the form "ErrUserNotFound ..."
ErrUserNotFound = errors.New("user not found")
// Group not found error
// ErrGroupNotFound

Check failure on line 33 in internal/aws/client.go

View workflow job for this annotation

GitHub Actions / test

comment on exported var ErrGroupNotFound should be of the form "ErrGroupNotFound ..."
ErrGroupNotFound = errors.New("group not found")
// User not specified error
// ErrUserNotSpecified

Check failure on line 35 in internal/aws/client.go

View workflow job for this annotation

GitHub Actions / test

comment on exported var ErrUserNotSpecified should be of the form "ErrUserNotSpecified ..."
ErrUserNotSpecified = errors.New("user not specified")
)

// ErrHTTPNotOK

Check failure on line 39 in internal/aws/client.go

View workflow job for this annotation

GitHub Actions / test

comment on exported type ErrHTTPNotOK should be of the form "ErrHTTPNotOK ..." (with optional leading article)
type ErrHTTPNotOK struct {
StatusCode int
}
Expand Down
5 changes: 5 additions & 0 deletions internal/sync.go
Original file line number Diff line number Diff line change
Expand Up @@ -882,6 +882,7 @@ func (s *syncGSuite) GetGroups() ([]*aws.Group, error) {
return awsGroups, nil
}

// ListGroupsPagesCallbackFn

Check failure on line 885 in internal/sync.go

View workflow job for this annotation

GitHub Actions / test

comment on exported function ListGroupsPagesCallbackFn should be of the form "ListGroupsPagesCallbackFn ..."
// Callback handler for paginated List of Groups
func ListGroupsPagesCallbackFn(page *identitystore.ListGroupsOutput, lastPage bool) bool {
// Loop through each Group returned
Expand Down Expand Up @@ -915,6 +916,7 @@ func (s *syncGSuite) GetUsers() ([]*aws.User, error) {
return awsUsers, nil
}

// ListUsersPagesCallbackFn

Check failure on line 919 in internal/sync.go

View workflow job for this annotation

GitHub Actions / test

comment on exported function ListUsersPagesCallbackFn should be of the form "ListUsersPagesCallbackFn ..."
// Callback handler for paginated List of Users
func ListUsersPagesCallbackFn(page *identitystore.ListUsersOutput, lastPage bool) bool {
// Loop through each User in ListUsersOutput and convert to native User object
Expand All @@ -924,6 +926,7 @@ func ListUsersPagesCallbackFn(page *identitystore.ListUsersOutput, lastPage bool
return !lastPage
}

// ConvertSdkUserObjToNative

Check failure on line 929 in internal/sync.go

View workflow job for this annotation

GitHub Actions / test

comment on exported function ConvertSdkUserObjToNative should be of the form "ConvertSdkUserObjToNative ..."
// Convert SDK user to native user object
func ConvertSdkUserObjToNative(user *identitystore.User) *aws.User {
// Convert emails into native Email object
Expand Down Expand Up @@ -969,6 +972,7 @@ func ConvertSdkUserObjToNative(user *identitystore.User) *aws.User {
}
}

// CreateUserIDtoUserObjMap

Check failure on line 975 in internal/sync.go

View workflow job for this annotation

GitHub Actions / test

comment on exported function CreateUserIDtoUserObjMap should be of the form "CreateUserIDtoUserObjMap ..."
// Create User ID for user object map
func CreateUserIDtoUserObjMap(awsUsers []*aws.User) map[string]*aws.User {
awsUsersMap := make(map[string]*aws.User)
Expand All @@ -980,6 +984,7 @@ func CreateUserIDtoUserObjMap(awsUsers []*aws.User) map[string]*aws.User {
return awsUsersMap
}

// ListGroupMembershipPagesCallbackFn

Check failure on line 987 in internal/sync.go

View workflow job for this annotation

GitHub Actions / test

comment on exported var ListGroupMembershipPagesCallbackFn should be of the form "ListGroupMembershipPagesCallbackFn ..."
// Handler for Paginated Group Membership List
var ListGroupMembershipPagesCallbackFn func(page *identitystore.ListGroupMembershipsOutput, lastPage bool) bool

Expand Down

0 comments on commit 96c34b0

Please sign in to comment.