aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarian Sollmann <marian.sollmann@cargomedia.ch>2013-10-28 15:31:58 +0100
committerRichard Gibson <richard.gibson@gmail.com>2013-11-06 10:37:06 -0500
commitff365d305fc22f40f4df9c4a6c7b1ca6c3c9800d (patch)
treeb770001899cd6e9ea1303b1e3470d94a57a78292
parent30eee925dbc9f8d465ccf064f48c24061ffdc378 (diff)
downloadjquery-ff365d305fc22f40f4df9c4a6c7b1ca6c3c9800d.tar.gz
jquery-ff365d305fc22f40f4df9c4a6c7b1ca6c3c9800d.zip
Fix #14190: Remove unnecessary assignment in .closest. Close gh-1411.
(cherry picked from commit 346b031af9e3b315ef351a9cc7fee56f930cf346) Conflicts: src/traversing.js
-rw-r--r--src/traversing.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/traversing.js b/src/traversing.js
index 4e55c8257..e3fc5cfa2 100644
--- a/src/traversing.js
+++ b/src/traversing.js
@@ -65,7 +65,7 @@ jQuery.fn.extend({
i = 0,
l = this.length,
matched = [],
- pos = ( rneedsContext.test( selectors ) || typeof selectors !== "string" ) ?
+ pos = rneedsContext.test( selectors ) || typeof selectors !== "string" ?
jQuery( selectors, context || this.context ) :
0;
@@ -79,7 +79,7 @@ jQuery.fn.extend({
cur.nodeType === 1 &&
jQuery.find.matchesSelector(cur, selectors)) ) {
- cur = matched.push( cur );
+ matched.push( cur );
break;
}
}