aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorItsLeeOwen2013-08-14 17:57:48 -0400
committerBrian Ford2013-08-14 17:01:58 -0700
commitec1cece270e293e7c55556fc68afee9a2ad40641 (patch)
treed25230b43b419590d776895833079714bff2e214 /src
parent4656e386fbc194f46e78682b56ce9135a45b7a78 (diff)
downloadangular.js-ec1cece270e293e7c55556fc68afee9a2ad40641.tar.bz2
fix(orderBy): remove redundant if statement
Removed unnecessary additional conditional statement.
Diffstat (limited to 'src')
-rw-r--r--src/ng/filter/orderBy.js6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ng/filter/orderBy.js b/src/ng/filter/orderBy.js
index d5a33836..d0b78553 100644
--- a/src/ng/filter/orderBy.js
+++ b/src/ng/filter/orderBy.js
@@ -125,8 +125,10 @@ function orderByFilter($parse){
var t1 = typeof v1;
var t2 = typeof v2;
if (t1 == t2) {
- if (t1 == "string") v1 = v1.toLowerCase();
- if (t1 == "string") v2 = v2.toLowerCase();
+ if (t1 == "string") {
+ v1 = v1.toLowerCase();
+ v2 = v2.toLowerCase();
+ }
if (v1 === v2) return 0;
return v1 < v2 ? -1 : 1;
} else {