1
0
mirror of https://github.com/mgechev/revive.git synced 2025-11-23 22:04:49 +02:00

fix(#1367): struct-tag with validate is missing built-in rules

This commit is contained in:
chavacava
2025-05-22 20:53:10 +02:00
committed by GitHub
parent 70c77d5be2
commit c73f766ea3
2 changed files with 138 additions and 95 deletions

View File

@@ -159,6 +159,7 @@ type ValidateUser struct {
BadComplex string `validate:"gt=0,keys,eq=1|eq=2,endkeys,required"` // MATCH /option "keys" must follow a "dive" option in validate tag/
BadComplex2 string `validate:"gt=0,dive,eq=1|eq=2,endkeys,required"` // MATCH /option "endkeys" without a previous "keys" option in validate tag/
BadComplex3 string `validate:"gt=0,dive,keys,eq=1|eq=2,endkeys,endkeys,required"` // MATCH /option "endkeys" without a previous "keys" option in validate tag/
Issue1367 string `validate:"required_without=ExternalValue,excluded_with=ExternalValue"`
}
type TomlUser struct {