Skip to content
Permalink
Browse files

Fix #13076. Speed up $() with strings, part of gh-1089.

  • Loading branch information...
hasclass authored and dmethvin committed Dec 18, 2012
1 parent 4de4be4 commit d8298046311e66a47424ec3f3cbe77e97bee3958
Showing with 3 additions and 3 deletions.
  1. +1 −1 AUTHORS.txt
  2. +2 −2 src/core.js
@@ -156,4 +156,4 @@ Matthias Jäggli <matthias.jaeggli@gmail.com>
Yiming He <yiminghe@gmail.com>
Devin Cooper <cooper.semantics@gmail.com>
Bennett Sorbo <bsorbo@gmail.com>
Sebastian Burkhard <sebi.burkhard@gmail.com>
@@ -96,8 +96,8 @@ jQuery.fn = jQuery.prototype = {
return this;
}

// HANDLE: $(DOMElement)
if ( selector.nodeType ) {
// HANDLE: $(DOMElement); check first that selector is not a primitive
if ( typeof selector === "object" && selector.nodeType ) {
this.context = this[0] = selector;
this.length = 1;
return this;

0 comments on commit d829804

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