Skip to content

Commit

Permalink
Omit select element when performing length check. (#685)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmjio authored Dec 18, 2021
1 parent 8332aa5 commit a34668a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jsbits/delegate.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ window['objectToJSON'] = function objectToJSON (at, obj) {

/* If obj is a list-like object */
var newObj;
if (obj instanceof Array || 'length' in obj) {
if (obj instanceof Array || ('length' in obj && obj['localName'] !== 'select')) {
newObj = [];
for (var i = 0; i < obj.length; i++)
newObj.push(window['objectToJSON']([], obj[i]));
Expand Down

0 comments on commit a34668a

Please sign in to comment.