Skip to content

Commit 752c198

Browse files
committed
[build] 1.0.10
1 parent c699f7a commit 752c198

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

dist/jquery.validator.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
/*! nice-validator 1.0.9
2-
* (c) 2012-2016 Jony Zhang <[email protected]>, MIT Licensed
1+
/*! nice-validator 1.0.10
2+
* (c) 2012-2017 Jony Zhang <[email protected]>, MIT Licensed
33
* https://github.com/niceue/nice-validator
44
*/
55
;(function(factory) {
@@ -1159,6 +1159,7 @@
11591159
tgt = isFunction(tgt) ? tgt.call(this, el) : this.$el.find(tgt);
11601160
if (tgt.length) {
11611161
if ( tgt.is(INPUT_SELECTOR) ) {
1162+
$el = tgt
11621163
el = tgt.get(0);
11631164
} else if ( tgt.hasClass(CLS_MSG_BOX) ) {
11641165
$msgbox = tgt;
@@ -1177,8 +1178,6 @@
11771178

11781179
// Create new message box
11791180
if (!msgOpt.hide && !$msgbox.length) {
1180-
$el = this.$el.find(tgt || el);
1181-
11821181
$msgbox = $('<'+ msgOpt.wrapper + '>').attr({
11831182
'class': CLS_MSG_BOX + (msgOpt.cls ? ' ' + msgOpt.cls : ''),
11841183
'style': msgOpt.style || undefined,
@@ -1233,7 +1232,7 @@
12331232
}
12341233

12351234
msgOpt = me._getMsgOpt(msgOpt, field);
1236-
el = $(el).get(0);
1235+
el = (el.name && _checkable(el) ? me.$el.find('input[name="'+ el.name +'"]') : $(el)).get(0);
12371236

12381237
// ok or tip
12391238
if (!msgOpt.msg && msgOpt.type !== 'error') {

0 commit comments

Comments
 (0)