refactor(orderBy): remove unneeded function wrapping

This commit is contained in:
kwypchlo
2014-12-16 00:36:25 +01:00
committed by Lucas Galfaso
parent fb2c585897
commit 83f88c1818

View File

@@ -130,9 +130,7 @@ function orderByFilter($parse) {
}
if (predicate === '') {
// Effectively no predicate was passed so we compare identity
return reverseComparator(function(a, b) {
return compare(a, b);
}, descending);
return reverseComparator(compare, descending);
}
get = $parse(predicate);
if (get.constant) {