rawlinp commented on a change in pull request #5225:
URL: https://github.com/apache/trafficcontrol/pull/5225#discussion_r514526924



##########
File path: traffic_ops/traffic_ops_golang/servicecategory/servicecategories.go
##########
@@ -112,8 +106,7 @@ func (serviceCategory *TOServiceCategory) 
SelectMaxLastUpdatedQuery(where, order
 
 func (serviceCategory TOServiceCategory) Validate() error {
        errs := validation.Errors{
-               "name":     validation.Validate(serviceCategory.Name, 
validation.NotNil, validation.Required),
-               "tenantId": validation.Validate(serviceCategory.TenantID, 
validation.Min(1)),
+               "name": validation.Validate(serviceCategory.Name, 
validation.NotNil, validation.Required),

Review comment:
       `validation.NotNil` is redundant when this already has 
`validation.Required`




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to