diff --git a/data_source.go b/data_source.go index 8a4eae1..6c1fa1e 100644 --- a/data_source.go +++ b/data_source.go @@ -325,7 +325,7 @@ func (d *StructData) parseRulesFromTag(v *Validation) { // collect rules from sub-struct and from arrays/slices elements // TODO should use ft == timeType check time.Time - if !strings.Contains(ft.Name(), "Time") { + if ft != timeType { if fValue.Type().Kind() == reflect.Ptr && fValue.IsNil() { continue }