From f3f2e7f50ee23aef2991a013395e081213bc0979 Mon Sep 17 00:00:00 2001 From: jlukic Date: Fri, 5 Jun 2015 16:28:43 -0400 Subject: [PATCH] Simplify debug on blur --- src/definitions/behaviors/form.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/definitions/behaviors/form.js b/src/definitions/behaviors/form.js index 0f813b6cc..6ae9ac323 100644 --- a/src/definitions/behaviors/form.js +++ b/src/definitions/behaviors/form.js @@ -272,15 +272,16 @@ $.fn.form = function(parameters) { }, blur: function() { var - $field = $(this), - $fieldGroup = $field.closest($group) + $field = $(this), + $fieldGroup = $field.closest($group), + validationRules = module.get.validation($field) ; if( $fieldGroup.hasClass(className.error) ) { - module.debug('Revalidating field', $field, module.get.validation($field)); - module.validate.field( module.get.validation($field) ); + module.debug('Revalidating field', $field, validationRules); + module.validate.field( validationRules ); } else if(settings.on == 'blur' || settings.on == 'change') { - module.validate.field( module.get.validation($field) ); + module.validate.field( validationRules ); } }, change: function() {