From: r.bogacki Date: Wed, 24 Jul 2019 07:06:26 +0000 (+0200) Subject: Major Sonar fixes in InstanceManagement X-Git-Tag: 1.5.2~190^2 X-Git-Url: https://gerrit.onap.org/r/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F16%2F91916%2F1;p=so.git Major Sonar fixes in InstanceManagement -Removed unnecessary code. -Removed unused variables. Issue-ID: SO-2102 Signed-off-by: Robert Bogacki Change-Id: Ie85cb51da959dacc80b61aa9d5bb608b4198a5fb --- diff --git a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/onap/so/apihandlerinfra/InstanceManagement.java b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/onap/so/apihandlerinfra/InstanceManagement.java index d8a7cb3f5d..ade13e7b57 100644 --- a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/onap/so/apihandlerinfra/InstanceManagement.java +++ b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/onap/so/apihandlerinfra/InstanceManagement.java @@ -105,13 +105,9 @@ public class InstanceManagement { private Response processCustomWorkflowRequest(String requestJSON, Actions action, HashMap instanceIdMap, String version, String requestId, ContainerRequestContext requestContext) throws ApiException { - String serviceInstanceId = null; - if (instanceIdMap != null) { - serviceInstanceId = instanceIdMap.get("serviceInstanceId"); - } + String serviceInstanceId; Boolean aLaCarte = true; - long startTime = System.currentTimeMillis(); - ServiceInstancesRequest sir = null; + ServiceInstancesRequest sir; String apiVersion = version.substring(1); String requestUri = requestHandlerUtils.getRequestUri(requestContext, uriPrefix);