v1.3.0
This commit is contained in:
@@ -11,6 +11,11 @@ func ValidateRequest(req interface{}) error {
|
||||
return validate.Struct(req)
|
||||
}
|
||||
|
||||
func ValidateConfig(cfg interface{}) error {
|
||||
validate := getDecortValidator()
|
||||
return validate.Struct(cfg)
|
||||
}
|
||||
|
||||
func ValidationError(fe validator.FieldError) error {
|
||||
return errors.New(errorMessage(fe))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user