mirror of
https://github.com/gin-gonic/gin.git
synced 2025-10-15 13:02:14 +08:00
Merge 9a8621cea1ac7ae0b66f912890cdae1b66f9587f into 94415333ed58f2677d0e3c2d902e111ddc56ccb8
This commit is contained in:
commit
0e34a6a9d6
@ -174,6 +174,11 @@ func Validate(obj interface{}) error {
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// skip unexported fields
|
||||||
|
if field.PkgPath != "" {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
fieldValue := val.Field(i).Interface()
|
fieldValue := val.Field(i).Interface()
|
||||||
zero := reflect.Zero(field.Type).Interface()
|
zero := reflect.Zero(field.Type).Interface()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user