Preparing report...

Report for github.com/jackmcguire1/UserService

A    Great!    Found 13 issues across 14 files

Tweet

gofmt92%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo92%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.


golint14%

Golint is a linter for Go source code.

    • UserService/dom/user/service.go
    • Line 3: warning: exported type UserUpdate should have comment or be unexported (golint)
    • Line 8: warning: exported type UserService should have comment or be unexported (golint)
    • Line 15: warning: exported type Resources should have comment or be unexported (golint)
    • Line 24: warning: exported function NewService should have comment or be unexported (golint)
    • UserService/pkg/utils/errors.go
    • Line 6: warning: exported var ErrNotFound should have comment or be unexported (golint)
    • Line 7: warning: error var AlreadyExists should have name of the form ErrFoo (golint)
    • Line 8: warning: error var ValidationErr should have name of the form ErrFoo (golint)
    • UserService/dom/user/elasticrepo.go
    • Line 12: warning: exported type ElasticSearchRepository should have comment or be unexported (golint)
    • Line 21: warning: exported type ElasticSearchParams should have comment or be unexported (golint)
    • Line 28: warning: exported function NewElasticRepo should have comment or be unexported (golint)
    • Line 57: warning: exported method ElasticSearchRepository.GetUser should have comment or be unexported (golint)
    • Line 67: warning: exported method ElasticSearchRepository.GetUsersByCountry should have comment or be unexported (golint)
    • Line 101: warning: exported method ElasticSearchRepository.PutUser should have comment or be unexported (golint)
    • Line 110: warning: exported method ElasticSearchRepository.DeleteUser should have comment or be unexported (golint)
    • UserService/dom/user/mockrepository.go
    • Line 7: warning: exported type MockRepository should have comment or be unexported (golint)
    • Line 13: warning: exported method MockRepository.GetUser should have comment or be unexported (golint)
    • Line 23: warning: exported method MockRepository.PutUser should have comment or be unexported (golint)
    • Line 28: warning: exported method MockRepository.GetUsersByCountry should have comment or be unexported (golint)
    • Line 38: warning: exported method MockRepository.DeleteUser should have comment or be unexported (golint)
    • UserService/dom/user/repository.go
    • Line 5: warning: error var NotImplementedErr should have name of the form ErrFoo (golint)
    • Line 5: warning: exported var NotImplementedErr should have comment or be unexported (golint)
    • Line 7: warning: exported type Repository should have comment or be unexported (golint)
    • Line 14: warning: exported type BaseRepository should have comment or be unexported (golint)
    • Line 16: warning: exported method BaseRepository.GetUser should have comment or be unexported (golint)
    • Line 20: warning: exported method BaseRepository.PutUser should have comment or be unexported (golint)
    • Line 24: warning: exported method BaseRepository.DeleteUser should have comment or be unexported (golint)
    • Line 28: warning: exported method BaseRepository.GetUsersByCountry should have comment or be unexported (golint)
    • UserService/pkg/elasticsearch/index.go
    • Line 14: warning: exported method ElasticSearch.CreateIndex should have comment or be unexported (golint)
    • Line 37: warning: exported method ElasticSearch.PutDoc should have comment or be unexported (golint)
    • Line 49: warning: exported method ElasticSearch.GetDoc should have comment or be unexported (golint)
    • Line 82: warning: exported method ElasticSearch.DeleteDoc should have comment or be unexported (golint)
    • Line 109: warning: exported method ElasticSearch.Query should have comment or be unexported (golint)
    • Line 121: warning: exported method ElasticSearch.DeleteIndex should have comment or be unexported (golint)
    • Line 128: warning: exported method ElasticSearch.PutMapping should have comment or be unexported (golint)
    • UserService/pkg/elasticsearch/es.go
    • Line 9: warning: exported type ElasticSearch should have comment or be unexported (golint)
    • Line 15: warning: exported type ElasticSearchClientReq should have comment or be unexported (golint)
    • Line 23: warning: exported function New should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign92%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!