Skip to content

Commit

Permalink
Selector: Bring back querySelectorAll shortcut usage
Browse files Browse the repository at this point in the history
Due to a faulty IE 8 workaround removal, the fast path qSA mode was skipped
when jQuery's find was called on an element node - i.e. in most cases. 😱

Ref gh-4395
Closes gh-4452
  • Loading branch information
mgol committed Aug 9, 2019
1 parent 4783596 commit cef4b73
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/selector.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,8 +218,7 @@ function find( selector, context, results, seed ) {

// Take advantage of querySelectorAll
if ( !nonnativeSelectorCache[ selector + " " ] &&
( !rbuggyQSA || !rbuggyQSA.test( selector ) ) &&
nodeType !== 1 ) {
( !rbuggyQSA || !rbuggyQSA.test( selector ) ) ) {

newSelector = selector;
newContext = context;
Expand Down

0 comments on commit cef4b73

Please sign in to comment.