Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
return false;
}
+ if ( obj.nodeType === 1 && length ) {
+ return true;
+ }
+
return type === "array" || type !== "function" &&
( length === 0 ||
typeof length === "number" && length > 0 && ( length - 1 ) in obj );
equal( jQuery.makeArray(/a/)[0].constructor, RegExp, "Pass makeArray a regex" );
- ok( jQuery.makeArray(document.getElementById("form")).length >= 13, "Pass makeArray a form (treat as elements)" );
+ // Some nodes inherit traits of nodelists
+ ok( jQuery.makeArray(document.getElementById("form")).length >= 13,
+ "Pass makeArray a form (treat as elements)" );
});
test("jQuery.inArray", function(){