You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With this task must be possible to use the dive Tag:
// User contains user information
type User struct {
FirstName string `validate:"required"`
LastName string `validate:"required"`
Addresses []*Address `validate:"required,dive,required"` // a person can have a home and cottage...
}
// Address houses a users address information
type Address struct {
Street string `validate:"required"`
City string `validate:"required"`
Planet string `validate:"required"`
Phone string `validate:"required"`
}
With dive there will also be "deep validation" in the address structure.
The text was updated successfully, but these errors were encountered:
With this task must be possible to use the dive Tag:
With dive there will also be "deep validation" in the address structure.
The text was updated successfully, but these errors were encountered: