X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fcore.js;h=56a2b1f1c5475f3996d4158ee3c8d601b5ae35f1;hb=3a7b09e5c747a9bf1386d667c7abed9630097072;hp=27cdbfe1fff23610a704304a660a01a39513cf02;hpb=da76a723e14c037d59e830bb0d01b0b627286020;p=jquery.git diff --git a/src/core.js b/src/core.js index 27cdbfe..56a2b1f 100644 --- a/src/core.js +++ b/src/core.js @@ -410,9 +410,7 @@ jQuery.fn = jQuery.prototype = { jQuery.inArray(this.name, value) >= 0); else if ( jQuery.nodeName( this, "select" ) ) { - var values = value.constructor == Array ? - value : - [ value ]; + var values = jQuery.makeArray(value); jQuery( "option", this ).each(function(){ this.selected = (jQuery.inArray( this.value, values ) >= 0 ||