mirror of
https://github.com/superseriousbusiness/gotosocial
synced 2025-06-05 21:59:39 +02:00
[chore] Bump github.com/go-playground/validator/v10 from 10.11.0 to 10.11.1 (#980)
Bumps [github.com/go-playground/validator/v10](https://github.com/go-playground/validator) from 10.11.0 to 10.11.1. - [Release notes](https://github.com/go-playground/validator/releases) - [Commits](https://github.com/go-playground/validator/compare/v10.11.0...v10.11.1) --- updated-dependencies: - dependency-name: github.com/go-playground/validator/v10 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
This commit is contained in:
11
vendor/github.com/go-playground/validator/v10/baked_in.go
generated
vendored
11
vendor/github.com/go-playground/validator/v10/baked_in.go
generated
vendored
@ -1484,10 +1484,15 @@ func isAlphaUnicode(fl FieldLevel) bool {
|
||||
return alphaUnicodeRegex.MatchString(fl.Field().String())
|
||||
}
|
||||
|
||||
// isBoolean is the validation function for validating if the current field's value can be safely converted to a boolean.
|
||||
// isBoolean is the validation function for validating if the current field's value is a valid boolean value or can be safely converted to a boolean value.
|
||||
func isBoolean(fl FieldLevel) bool {
|
||||
_, err := strconv.ParseBool(fl.Field().String())
|
||||
return err == nil
|
||||
switch fl.Field().Kind() {
|
||||
case reflect.Bool:
|
||||
return true
|
||||
default:
|
||||
_, err := strconv.ParseBool(fl.Field().String())
|
||||
return err == nil
|
||||
}
|
||||
}
|
||||
|
||||
// isDefault is the opposite of required aka hasValue
|
||||
|
Reference in New Issue
Block a user