ReactiveRaven / jqBootstrapValidation

A JQuery validation framework for bootstrap forms.
http://reactiveraven.github.io/jqBootstrapValidation
MIT License
1.35k stars 334 forks source link

"TypeError: obj is undefined" in jQuery.each function with select #186

Open FriendOfTheNight opened 8 years ago

FriendOfTheNight commented 8 years ago

When using the Chosen library (https://github.com/harvesthq/chosen) with jqBootstrapValidation I'm getting "TypeError: obj is undefined" in the jQuery.each function every time I open the drop-down.

The issue is here: $.each($(el).triggerHandler("validation.validation", params), function (j, message) {

since "$(el).triggerHandler("validation.validation", params)" is coming back undefined.

It looks like this was already fixed on the master branch:

$.each($(el).triggerHandler("validation.validation", params) || [], function (j, message) {