BugFix:unable to handle resourceType with space 67/62367/1
authorPhillip Leigh <phillip.leigh@amdocs.com>
Fri, 24 Aug 2018 16:11:35 +0000 (12:11 -0400)
committerPhillip Leigh <phillip.leigh@amdocs.com>
Fri, 24 Aug 2018 16:11:57 +0000 (12:11 -0400)
Issue-ID: SDNC-317
Change-Id: Id063ea3b29f96ee786a29352311f79c9e24432ac
Signed-off-by: Phillip Leigh <phillip.leigh@amdocs.com>
pomba/service-decomposition/src/main/java/org/onap/sdnc/apps/pomba/servicedecomposition/util/RestUtil.java

index c9e2c50..99a929a 100644 (file)
@@ -349,7 +349,8 @@ public class RestUtil {
 
     private static List<Resource> getResourceTypes(String aaiResourceList) {
         List<Resource> resources = new ArrayList<Resource>();
-        String[] resourceList = aaiResourceList.split(",");
+        String noSpaceAaiResourceList = aaiResourceList.replaceAll("\\s", "");
+        String[] resourceList = noSpaceAaiResourceList.split(",");
         for (int i = 0; i < resourceList.length; i++) {
                 resources.add(new Resource(resourceList[i]));
         }