We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v.StringRule("code", required|regex:\d{4,6})
required|regex:\d{4,6}
panic: validate: the number of parameters given does not match the required. validator 'regex', want 2, given 3 goroutine 1 [running]: validate.panicf(...) validate/helper.go:287 validate.(*funcMeta).checkArgNum(0xc0000c7dc0, 0x3, 0x13ab011, 0x5) validate/validators.go:198 +0x1b6 validate.(*Rule).valueValidate(0xc0001ee000, 0x13a874a, 0x4, 0x13a8e15, 0x6, 0x13a8301, 0x1331a60, 0xc0000bae30, 0xc0000f22c0, 0x0) validate/validate.go:166 +0x1c7 validate.(*Rule).Apply(0xc0001ee000, 0xc0000f22c0, 0x0) validate/validate.go:83 +0x6c0 validate.(*Validation).Validate(0xc0000f22c0, 0x0, 0x0, 0x0, 0xd) validate/validation.go:332 +0x10c exit status 2
The text was updated successfully, but these errors were encountered:
95eea92
感谢你的报告。
已经修复了,正则包含逗号 解析为多个参数了。
Sorry, something went wrong.
inhere
No branches or pull requests
The text was updated successfully, but these errors were encountered: