lib/padrino-admin/generators/templates/assets/javascripts/application.js in padrino-admin-0.11.4 vs lib/padrino-admin/generators/templates/assets/javascripts/application.js in padrino-admin-0.12.0.rc1
- old
+ new
@@ -110,8 +110,9 @@
generalToggle();
});
}
// Autofocus first field with an error. (usability)
- $('.has-error :input').first().focus();
+ var error_input;
+ if (error_input = $('.has-error :input').first()) { error_input.focus(); }
});
}(window.jQuery);