Update pkg/apis/coordination/validation/validation.go

Co-authored-by: Katrina Verey <kn.verey@gmail.com>
This commit is contained in:
Sebastian Sterk 2022-02-03 18:25:43 +01:00 committed by GitHub
parent 8e9ea7b481
commit efdfaab301
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -46,7 +46,7 @@ func ValidateLeaseSpec(spec *coordination.LeaseSpec, fldPath *field.Path) field.
}
if spec.LeaseTransitions != nil && *spec.LeaseTransitions < 0 {
fld := fldPath.Child("leaseTransitions")
allErrs = append(allErrs, field.Invalid(fld, spec.LeaseTransitions, "must be greater or equal than 0"))
allErrs = append(allErrs, field.Invalid(fld, spec.LeaseTransitions, "must be greater than or equal to 0"))
}
return allErrs
}