portainer/portainer

View on GitHub
api/http/handler/teams/team_list.go

Summary

Maintainability
A
40 mins
Test Coverage

Method Handler.teamList has 6 return statements (exceeds 4 allowed).
Open

func (handler *Handler) teamList(w http.ResponseWriter, r *http.Request) *httperror.HandlerError {
    teams, err := handler.DataStore.Team().ReadAll()
    if err != nil {
        return httperror.InternalServerError("Unable to retrieve teams from the database", err)
    }
Severity: Major
Found in api/http/handler/teams/team_list.go - About 40 mins to fix

    There are no issues that match your filters.

    Category
    Status