We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents b1b3b1c + 6ac76ce commit f86eb06Copy full SHA for f86eb06
src/validator/validator.js
@@ -258,10 +258,10 @@
258
return v === '' || new RegExp("^" + el.attr("pattern") + "$").test(v);
259
});
260
261
- v.fn(":radio", "Please select an option.", function(el) {
+ v.fn(":radio[required]", "Please select an option.", function(el) {
262
var checked = false;
263
var els = $("[name='" + el.attr("name") + "']").each(function(i, el) {
264
- if ($(el).is(":checked")) {
+ if ($(el).is(":checked") || checked) {
265
checked = true;
266
}
267
0 commit comments