Skip to content

Commit

Permalink
[FIX] borrow slice from prototype
Browse files Browse the repository at this point in the history
  • Loading branch information
Planeshifter committed Jun 9, 2015
1 parent 913e044 commit 8fdc65f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/array.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ function midmean( arr, sorted ) {
}

if ( !sorted ) {
arr = arr.slice();
// Borrow prototype method as typed arrays do not have sort
arr = Array.prototype.slice.call( arr );
// Borrow prototype method as typed arrays do not have sort
Array.prototype.sort.call( arr, ascending );
}

Expand Down

0 comments on commit 8fdc65f

Please sign in to comment.