cloudfoundry/cf-k8s-controllers

View on GitHub
controllers/webhooks/networking/routes/validator.go

Summary

Maintainability
A
35 mins
Test Coverage

Method Validator.ValidateUpdate has 9 return statements (exceeds 8 allowed).
Open

func (v *Validator) ValidateUpdate(ctx context.Context, oldObj, obj runtime.Object) (admission.Warnings, error) {
    route, ok := obj.(*korifiv1alpha1.CFRoute)
    if !ok {
        return nil, apierrors.NewBadRequest(fmt.Sprintf("expected a CFRoute but got a %T", obj))
    }
Severity: Major
Found in controllers/webhooks/networking/routes/validator.go - About 35 mins to fix

    There are no issues that match your filters.

    Category
    Status