Skip to main content

Bug Tracker

Side navigation

Ticket #910: clean.diff
File clean.diff, 0.5 KB (added by brandon, February 24, 2007 04:46AM UTC)

patch

Index: jquery/src/jquery/jquery.js
===================================================================
--- jquery/src/jquery/jquery.js	(revision 1410)
+++ jquery/src/jquery/jquery.js	(working copy)
@@ -1469,10 +1469,10 @@
 				arg = div.childNodes;
 			}
 
-			if ( arg.length === 0 )
+			if ( arg.length === 0 && !jQuery.nodeName(arg, "form") )
 				return;
 			
-			if ( arg[0] == undefined )
+			if ( arg[0] == undefined || jQuery.nodeName(arg, "form") )
 				r.push( arg );
 			else
 				r = jQuery.merge( r, arg );

Download in other formats:

Original Format