mirror of
https://github.com/jquery/jquery.git
synced 2026-02-07 16:04:57 -05:00
Coerce eq() argument all the time. Fixes #10616
This commit is contained in:
committed by
Dave Methvin
parent
e086c22826
commit
7cbd7a640f
@@ -264,9 +264,10 @@ jQuery.fn = jQuery.prototype = {
|
||||
},
|
||||
|
||||
eq: function( i ) {
|
||||
i = +i;
|
||||
return i === -1 ?
|
||||
this.slice( i ) :
|
||||
this.slice( i, +i + 1 );
|
||||
this.slice( i, i + 1 );
|
||||
},
|
||||
|
||||
first: function() {
|
||||
|
||||
Reference in New Issue
Block a user