portainer/portainer

View on GitHub
api/http/handler/hostmanagement/fdo/profile_duplicate.go

Summary

Maintainability
A
50 mins
Test Coverage

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

func (handler *Handler) duplicateProfile(w http.ResponseWriter, r *http.Request) *httperror.HandlerError {
    id, err := request.RetrieveNumericRouteVariableValue(r, "id")
    if err != nil {
        return httperror.BadRequest("Bad request", errors.New("missing 'id' query parameter"))
    }
Severity: Major
Found in api/http/handler/hostmanagement/fdo/profile_duplicate.go - About 50 mins to fix

    There are no issues that match your filters.

    Category
    Status