Delg,ListActivity,ListApprovals.java-remove useless assignments 98/98098/2
authorThugutla sailakshmi <tsaila10@in.ibm.com>
Thu, 7 Nov 2019 07:46:35 +0000 (13:16 +0530)
committerJonathan Gathman <jonathan.gathman@att.com>
Thu, 21 Nov 2019 15:32:04 +0000 (15:32 +0000)
Issue-ID: AAF-876
Change-Id: I60413575372f23d0d2b77aa9ec17afb62a2bb657
Signed-off-by: Thugutla sailakshmi <tsaila10@in.ibm.com>
auth/auth-cmd/src/main/java/org/onap/aaf/auth/cmd/user/Delg.java
auth/auth-cmd/src/main/java/org/onap/aaf/auth/cmd/user/ListActivity.java
auth/auth-cmd/src/main/java/org/onap/aaf/auth/cmd/user/ListApprovals.java

index f5cb449..6e96728 100644 (file)
@@ -72,7 +72,7 @@ public class Delg extends BaseCmd<User> {
                     if (option<2 && args.length>idx) {
                         Date date;
                         try {
-                            date = Chrono.dateOnlyFmt.parse(args[idx++]);
+                            date = Chrono.dateOnlyFmt.parse(args[idx]);
                         } catch (ParseException e) {
                             throw new CadiException(e);
                         }
index 30c71e5..485e6d1 100644 (file)
@@ -47,9 +47,8 @@ public class ListActivity extends Cmd {
     }
 
     @Override
-    public int _exec(int _idx, final String ... args) throws CadiException, APIException, LocatorException {
-            int idx = _idx;
-        final String user = fullID(args[idx++]);
+    public int _exec(final int idx, final String ... args) throws CadiException, APIException, LocatorException {
+        final String user = fullID(args[idx]);
         return same(new Retryable<Integer>() {
             @Override
             public Integer code(Rcli<?> client) throws CadiException, APIException {
index 765bd0a..17f3002 100644 (file)
@@ -50,10 +50,10 @@ public class ListApprovals extends Cmd {
 
     @Override
     public int _exec(int _idx, final String ... args) throws CadiException, APIException, LocatorException {
-            int idx = _idx;
+        int idx = _idx;
         final String type = args[idx++];
         int option = whichOption(options,type);
-        String value = args[idx++];
+        String value = args[idx];
         final String fullValue;
         if (option != 2) {
             fullValue = fullID(value);