- add e164, unique, json, jwt, lowercase, uppercase, datetime, postcode_iso3166_alpha2, postcode_iso3166_alpha2_field
- update ip4_addr, ip6_addr, unix_addr
- remove some empty line to match with en.go (make it easier to compare)
* Use ja locale instead of en in ja_test.go
* Comment out calling ut.AddCardinal with locales.PluralRuleOne
because cardinal plural rule 'One' does not exist for locale 'ja'.
Validates that a string or number value equals one of a set of allowed values. Examples:
validator.Var(“red”, “oneof=red green”)
validator.Var(6, “oneof=6 7 8”)
Previously, if fields were of kind `reflect.Ptr`, the translation of
validation errors used the default string, resulting in unexpected
output.
Now the default translations use the field's `Elem()` kind (for example
for `*string` the `Elem()` is `string`), resulting in much more natural
output.
Running goimports on the codebase deletes all the imports of "github.com/go-playground/universal-translator".
The fix consists of explicitly qualifying the import statements with ut.
- or's weren't reporting the param back in the tag, long standing but noticed issue.
- added validation check for or's when more validations exist after the or.