Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New() *validator.Validate
New returns a new validator.Validate instance that is configured to recognize struct tags of the form "json", and to validate the "alphaspace" tag. The value of the "json" tag is used as the name of the field in error messages. If the value is '-', the field is ignored.
Types ¶
type ErrResponse ¶
type ErrResponse struct {
Errors []string `json:"errors"`
}
func ToErrResponse ¶
func ToErrResponse(err error) *ErrResponse
Click to show internal directories.
Click to hide internal directories.