Skip to content
Permalink
Browse files

Fixed issue with $( obj, jQuery ) breaking the original jQuery object.

  • Loading branch information
jeresig committed Aug 20, 2006
1 parent 367abc3 commit 8ff329b0f346ea5282e76dc7fa7f91a79d6ff8eb
Showing with 4 additions and 2 deletions.
  1. +4 −2 src/jquery/jquery.js
@@ -59,10 +59,12 @@ function jQuery(a,c) {
*/

// Watch for when a jQuery object is passed as the selector
if ( a.jquery ) return a;
if ( a.jquery )
return $( jQuery.merge( a, [] ) );

// Watch for when a jQuery object is passed at the context
if ( c && c.jquery ) return c.find(a);
if ( c && c.jquery )
return $( c ).find(a);

// If the context is global, return a new object
if ( window == this )

0 comments on commit 8ff329b

Please sign in to comment.
You can’t perform that action at this time.