commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1364371 - /commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java
Date Sun, 22 Jul 2012 17:23:13 GMT
Author: tn
Date: Sun Jul 22 17:23:12 2012
New Revision: 1364371

URL: http://svn.apache.org/viewvc?rev=1364371&view=rev
Log:
Combined two subsequent if statements, reported by pmd.

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java?rev=1364371&r1=1364370&r2=1364371&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java
(original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/stat/regression/MillerUpdatingRegression.java
Sun Jul 22 17:23:12 2012
@@ -845,15 +845,13 @@ public class MillerUpdatingRegression im
         while (i < nvars) {
             l = vorder[i];
             for (int j = 0; j < list.length; j++) {
-                if (l == list[j]) {
-                    if (i > next) {
-                        this.vmove(i, next);
-                        ++next;
-                        if (next >= list.length + pos1) {
-                            return 0;
-                        } else {
-                            break;
-                        }
+                if (l == list[j] && i > next) {
+                    this.vmove(i, next);
+                    ++next;
+                    if (next >= list.length + pos1) {
+                        return 0;
+                    } else {
+                        break;
                     }
                 }
             }



Mime
View raw message