Closed dvrgoc closed 4 months ago
Thanks for your PR!
I'm concerned in that this is a change to a library file, jquery.validate.js
. Current version of it is 1.19.5. Latest is 1.20.1. Is it fixed in the latest validate version?
Ultimately I think it should either be fixed there (and this file brought up to date), or fixed outside in a way that overrides the library behavior. We shouldn't be changing third party library code directly unless there's a very strong reason. Is there here?
Closing as out of scope for this project. It should be addressed in jQuery Validate.
Description (*)
If attribute based rules are used to specify validation of a field in HTML, incorrect type is used when validating. For example, validation rule is
ipv4
and has assigned a value of true and is processed as String, but should be Boolean instead.<input name="field" ipv4="true" ... />
Related Pull Requests
N/A
Fixed Issues (if relevant)
N/A
Manual testing scenarios (*)
custom-form.phtml
)rules
method:// debug the value if (!!$.validator.attributeRules(element) && Object.keys($.validator.attributeRules(element)).length > 0) { console.log($.validator.attributeRules(element)); } ...