From: John Resig Date: Thu, 23 Jul 2009 22:38:29 +0000 (+0000) Subject: Changed .get(-Number) to use .slice() instead of .toArray() (which doesn't take any... X-Git-Url: http://git.asbjorn.biz/?a=commitdiff_plain;h=26eda09892459709d224f910038b8f6836bfd012;hp=9c9dd7cedea56a350d49ddcdf0982be9fcb6bad2;p=jquery.git Changed .get(-Number) to use .slice() instead of .toArray() (which doesn't take any arguments). Follow-up from commit [6484]. --- diff --git a/src/core.js b/src/core.js index 7281b44..cb9b528 100644 --- a/src/core.js +++ b/src/core.js @@ -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