Changed .get(-Number) to use .slice() instead of .toArray() (which doesn't take any arguments). Follow-up from commit [6484].

This commit is contained in:
John Resig 2009-07-23 22:38:29 +00:00
parent 9c9dd7cede
commit 26eda09892

View file

@ -141,7 +141,7 @@ jQuery.fn = jQuery.prototype = {
this.toArray() :
// Return just the object
( num < 0 ? this.toArray(num)[ 0 ] : this[ num ] );
( num < 0 ? this.slice(num)[ 0 ] : this[ num ] );
},
// Take an array of elements and push it onto the stack