portainer/portainer

View on GitHub
api/http/handler/helm/helm_install.go

Summary

Maintainability
A
1 hr
Test Coverage

Method Handler.updateHelmAppManifest has 9 return statements (exceeds 4 allowed).
Open

func (handler *Handler) updateHelmAppManifest(r *http.Request, manifest []byte, namespace string) error {
    endpoint, err := middlewares.FetchEndpoint(r)
    if err != nil {
        return errors.Wrap(err, "unable to find an endpoint on request context")
    }
Severity: Major
Found in api/http/handler/helm/helm_install.go - About 55 mins to fix

    Method Handler.installChart has 8 return statements (exceeds 4 allowed).
    Open

    func (handler *Handler) installChart(r *http.Request, p installChartPayload) (*release.Release, error) {
        clusterAccess, httperr := handler.getHelmClusterAccess(r)
        if httperr != nil {
            return nil, httperr.Err
        }
    Severity: Major
    Found in api/http/handler/helm/helm_install.go - About 50 mins to fix

      There are no issues that match your filters.

      Category
      Status