We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 14ff529 commit 8eabc54Copy full SHA for 8eabc54
src/ng/filter/orderBy.js
@@ -146,9 +146,7 @@ function orderByFilter($parse) {
146
return compare(get(a),get(b));
147
}, descending);
148
});
149
- var arrayCopy = [];
150
- for (var i = 0; i < array.length; i++) { arrayCopy.push(array[i]); }
151
- return arrayCopy.sort(reverseComparator(comparator, reverseOrder));
+ return slice.call(array).sort(reverseComparator(comparator, reverseOrder));
152
153
function comparator(o1, o2) {
154
for (var i = 0; i < sortPredicate.length; i++) {
0 commit comments