Merge "Extend.java-Extract the assignment out of the expression"
authorJonathan Gathman <jonathan.gathman@att.com>
Mon, 14 Oct 2019 21:00:46 +0000 (21:00 +0000)
committerGerrit Code Review <gerrit@onap.org>
Mon, 14 Oct 2019 21:00:46 +0000 (21:00 +0000)
1  2 
auth/auth-batch/src/main/java/org/onap/aaf/auth/batch/update/Extend.java

@@@ -138,8 -138,7 +138,8 @@@ public class Extend extends Batch 
                          int i = hi.get();
                          StringBuilder sb = hsb.get();
                          if(sb==null) {
 -                            hsb.set(sb=cqlBatch.begin());
 +                            sb=cqlBatch.begin();
 +                            hsb.set(sb);
                          }
                          switch(row.get(0)) {
                              case "info":
                          if(i%maxBatch==0 && sb!=null) {
                              cqlBatch.execute(dryRun);
                              hi.set(1);
-                             hsb.set(sb=null);
+                             sb=null;
+                             hsb.set(sb);
                          }
                      }
                  });